View Full Version : Warning messages.
May 17th, 2013, 11:14 AM
Just renewed an old licence and installed a new copy of the software here.
Upper Rissington Gallery - Upper Rissington Gallery (http://www.upperrissington.co.uk/gallery)
All looks fine until you click on a picture and the following two messages appear. Picture works - but the messages are listed above Photopost.
Warning: mysql_fetch_row() expects parameter 1 to be resource, boolean given in /home/<site>/public_html/gallery/forums/vb3.php on line 213
Warning: mysql_free_result() expects parameter 1 to be resource, boolean given in /home/<site>/public_html/gallery/pp-inc.php on line 622
I did look under your Support, but can't find anything to help. Although I know I've probably missed something.
May 17th, 2013, 12:18 PM
I would look at the files. I use vb4 and have no issues and its the same for any of the vb 3 4 5 releaes.
Your first issue might be that your userprofile field location does not exist on your install, You can if your logged in as admin in global options turn on debug option to display errors and save. You can then view the page and post me the error that shows. I can them comment but my guess would be this.
May 17th, 2013, 12:22 PM
This is the Error Message:
We're sorry, but the system experienced an unrecoverable error. Please try again later.
Query: SELECT u.username,u.homepage,u.usertitle,u.posts,u.joindate,uf.field2,s.host,t.signature,sigpic.filename,u.sigpicrevision,avatar.avatarpath, NOT ISNULL(customavatar.filedata) AS hascustomavatar,customavatar.dateline,customprofile.filename, u.avatarrevision FROM bbuser u LEFT JOIN bbuserfield uf ON uf.userid=u.userid LEFT JOIN bbsession s ON s.userid=u.userid LEFT JOIN bbusertextfield t ON t.userid=u.userid LEFT JOIN bbsigpic AS sigpic ON sigpic.userid=u.userid LEFT JOIN bbsigparsed AS sigparsed ON sigparsed.userid=u.userid LEFT JOIN bbavatar AS avatar ON (avatar.avatarid = u.avatarid) LEFT JOIN bbcustomavatar AS customavatar ON (customavatar.userid = u.userid) LEFT JOIN bbcustomprofilepic AS customprofile ON (customprofile.userid = u.userid) WHERE u.userid=1 LIMIT 1
Result: Unknown column 'uf.field2' in 'field list'
Database handle: Resource id #31
May 17th, 2013, 12:26 PM
Yes you can solve that issue by the link in my last post. ;) Thanks for posting the error makes it easy to confirm the issue. We do code for specific fields in a default vbulletin and that field is normally field2 in that userfields table. You can though in vb delete specific fields which causes this error.
May 17th, 2013, 01:07 PM
I think I understand. Field 2 is missing. Do you suggest delete all other fields (3,4 and 5) and then start over? Assuming the next new field would be 2.
Downside is that all the data under the other fields will be eradicated.
Is there some code I could past in? I tried to see where I could post the info you listed in Post 2 [ALTER TABLE userfield ADD field2 VARCHAR(75) DEFAULT NULL;] but couldn't find where to add it.
May 17th, 2013, 01:15 PM
No my suggestion would be to simply add the field back in. with the query I posted. Make sure to adjust for any site prefix you have.
May 17th, 2013, 10:15 PM
I have found the table and under 2 amended the script as suggested.
But I guess I'm doing something wrong as the failure message has not disappeared.
EDIT: Looked at the thread you linked too and I changed the vb3.php file line 187.
At long last I can chill.
May 18th, 2013, 07:15 AM
Your welcome glad to help
vBulletin® v3.8.1, Copyright ©2000-2014, Jelsoft Enterprises Ltd.