Page 1 of 1
MySQL Errors Since Updating to J1.7 and PD 2.0.1
Posted: 30 Jul 2011, 03:58
by jhale1966
It seems that since I've upgraded, whenever I go to list my files in the backend (Admin side), I get this:
Warning: mysql_num_rows(): supplied argument is not a valid MySQL result resource in /[ERASED]/html/libraries/joomla/database/database/mysql.php on line 282
Warning: mysql_num_rows(): supplied argument is not a valid MySQL result resource in /[ERASED]/html/libraries/joomla/database/database/mysql.php on line 282
Warning: mysql_num_rows(): supplied argument is not a valid MySQL result resource in /[ERASED]/html/libraries/joomla/database/database/mysql.php on line 282
And I can't access my files. What do I need to do to fix this?
Thanks!

Re: MySQL Errors Since Updating to J1.7 and PD 2.0.1
Posted: 30 Jul 2011, 15:21
by Jan
Hi, you need to enable debug mode to get information about the database error.
Jan
Re: MySQL Errors Since Updating to J1.7 and PD 2.0.1
Posted: 30 Jul 2011, 15:31
by jhale1966
Hi Jan!
Here's the error:
JDatabaseMySQL::query: 1054 - Unknown column 'a.userid' in 'on clause' SQL=SELECT a.*,l.title AS language_title,uc.name AS editor,uua.id AS uploaduserid, uua.username AS uploadusername, uua.name AS uploadname,ag.title AS access_level,c.title AS category_title, c.id AS category_id,ua.id AS userid, ua.username AS username, ua.name AS usernameno FROM `jos_phocadownload` AS a LEFT JOIN `jos_languages` AS l ON l.lang_code = a.language LEFT JOIN jos_users AS uc ON uc.id=a.checked_out LEFT JOIN jos_users AS uua ON uua.id=a.userid LEFT JOIN jos_viewlevels AS ag ON ag.id = a.access LEFT JOIN jos_phocadownload_categories AS c ON c.id = a.catid LEFT JOIN jos_users AS ua ON ua.id = a.owner_id WHERE a.published = 1 AND a.catid = 26 GROUP BY a.id ORDER BY a.title asc
Thanks!

Re: MySQL Errors Since Updating to J1.7 and PD 2.0.1
Posted: 30 Jul 2011, 17:04
by Jan
Hi, so it seems you have not installed the 2.0.0 stable, as this included the installation of a.userid column.
- you need to install Phoca Download 2.0.0 first (not upgrade)
- or run the install.sql.bak - the upgrade query of the userid column, search this forum, as there are info about this.
Jan
Re: MySQL Errors Since Updating to J1.7 and PD 2.0.1
Posted: 30 Jul 2011, 17:07
by jhale1966
Thanks Jan - I found an earlier post and when I ran this:
ALTER TABLE `jos_phocadownload` ADD `userid` int(11) NOT NULL Default '0' AFTER `description` ;
It seems to have fixed the problem. Thanks!

Re: MySQL Errors Since Updating to J1.7 and PD 2.0.1
Posted: 03 Aug 2011, 14:56
by Jan
Ok
Re: MySQL Errors Since Updating to J1.7 and PD 2.0.1
Posted: 25 Sep 2011, 19:39
by PGH
now i´m in the right topic. thx this helped me with the same problem