install.bak file queries into database. Please help!

Phoca Gallery - image gallery extension
broboa
Phoca Newbie
Phoca Newbie
Posts: 2
Joined: 26 Feb 2013, 04:28

install.bak file queries into database. Please help!

Post by broboa »

Hello!

I have a problem with Phoca Gallery using. I just have installed it. And I found same problems of other people in this forum. (I am trying to install Phoca Gallery 3.2.3 version.)
That I can not add anything in my gallery. I just have
Warning: mysql_num_rows(): supplied argument is not a valid MySQL result resource in Z:\home\localhost\www\libraries\joomla\database\database\mysql.php on line 293
This error when going to the images and categories.
https://www.phoca.cz/documents/2-phoca-g ... em-solving
Here you are showing the solution of this problem. And I realized that I need just to add everything except the ALTER TABLE codes.
But I am using database first time and have no idea how to make it:(
I am opening http://localhost/tools/phpmyadmin/ and then going into my database. Then I am selecting in menu the "SQL" and just adding this code from install.bak file.
Changed table prefixes instead of my '#__'.

Then opening my administration panel in joomla and the error is still on. I've tried also to reinstall Phoca Gallery. But nothing has changed.
Please, very need your help. Thank you in advance! :? All instructions have made but have no idea what I do wrong.
User avatar
Benno
Phoca Hero
Phoca Hero
Posts: 9971
Joined: 04 Dec 2008, 11:58
Location: Germany
Contact:

Re: install.bak file queries into database. Please help!

Post by Benno »

Hi,
first of all, you only need to create missing Phoca Gallery tables in you database manualy.
1.) Therefore, check which tables are missing.
Phoca Gallery v3.2.3 needs following tables:

Code: Select all

#__phocagallery
#__phocagallery_categories
#__phocagallery_votes
#__phocagallery_comments
#__phocagallery_votes_statistics
#__phocagallery_img_votes
#__phocagallery_img_votes_statistics
#__phocagallery_user
#__phocagallery_img_comments
#__phocagallery_fb_users
#__phocagallery_tags
#__phocagallery_tags_ref
Compare carefully.

2.) The next steps are an example!
In step 1.) you have found out, that two tables are missing:
#__phocagallery
#__phocagallery_categories

3.) Unzip the Phoca Gallery v.3.2.3 install package http://joomlacode.org/gf/download/frsre ... v3.2.3.zip local on your PC.
Open the file install.bak.sql with an editor like e.g. Notepad++ is.

4.) You will find this query starting with:

Code: Select all

CREATE TABLE `#__phocagallery` (
and:

Code: Select all

CREATE TABLE `#__phocagallery_categories` (
5.) change the table prefix #_ to your prefix

Code: Select all

CREATE TABLE `#__phocagallery` (
becomes:

Code: Select all

CREATE TABLE `yourprefix_phocagallery` (
and:

Code: Select all

CREATE TABLE `#__phocagallery_categories` (
becomes:

Code: Select all

CREATE TABLE `yourprefix_phocagallery_categories` (
Save your changes!

6. Open your data base with help of phpMyAdmin
Copy and paste the first with your database prefix changed query in the SQL window.
And press the GO Button.
See:
(In this example the prefix is j25_)
Image

7. Do the same with the second query:

Your Database should be fixed now and Phoca Gallery should work.

Kind regards,
Benno
broboa
Phoca Newbie
Phoca Newbie
Posts: 2
Joined: 26 Feb 2013, 04:28

Re: install.bak file queries into database. Please help!

Post by broboa »

Ohhhh, thank you very very much! I got it.
Only one issue. I had all those tables missed, not two:) Now I've done everything and works cool! Thank you very much:)
User avatar
Benno
Phoca Hero
Phoca Hero
Posts: 9971
Joined: 04 Dec 2008, 11:58
Location: Germany
Contact:

Re: install.bak file queries into database. Please help!

Post by Benno »

You're welcome!

Kind regards,
Benno
Post Reply