View Full Version : search -> SQL error

05 May 2011, 02:46 PM
with i get:
A Database Error Occurred

Error Number: 1064

You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '11)' at line 1

SELECT * FROM usergroup WHERE usergroupid IN (,11)

05 May 2011, 06:44 AM
not fixed yet. any statement?

05 May 2011, 05:46 AM
Thanks Jedie,
I'm not actually seeing the error (i'm getting a different error when i click on a search result however :sad: ). Is it all you see when you goto that URL, or do you have to click on a link?

and can you search for anything else fine?

05 May 2011, 07:15 AM
Yes, i see only this. The complete error page code is here:

But funny: This error comes only, if i logged in! If i not logged in, everything works fine.

05 May 2011, 10:19 PM
I'm having the same problem, exact same error message no matter what I search for. I'm not sure what that query is used for but if you either remove the comma from the (,11) or add another number in front of the comma it would fix the problem. If your just searching the database for 1 id use " WHERE usergroupid = '11' " the "WHERE IN" function is used to search through an array of multiple options...I'm sure whoever is working on the site knew that already but I thought I'd try and be helpful.

05 May 2011, 02:05 AM
All fixed!

Thank you both very much for your help.

CGTalk Moderation
05 May 2011, 02:05 AM
This thread has been automatically closed as it remained inactive for 12 months. If you wish to continue the discussion, please create a new thread in the appropriate forum.