Welcome to Geeklog, Anonymous Saturday, December 21 2024 @ 09:12 am EST
Geeklog Forums
MySQL errors in 1.7.0
James
Anonymous
We are getting a bunch of MySQL errors in our site. We just upgraded to 1.7.0 a couple of weeks ago. Here is one of them we get several times a day.
SELECT COUNT(*) FROM%' AND (title LIKE '%youtube%' OR introtext LIKE '%youtube%' OR bodytext LIKE '%youtube%')
Any suggestions of where to find this error and how to fix?
SELECT COUNT(*) FROM%' AND (title LIKE '%youtube%' OR introtext LIKE '%youtube%' OR bodytext LIKE '%youtube%')
Any suggestions of where to find this error and how to fix?
27
22
Quote
Status: offline
Dirk
Site Admin
Admin
Registered: 01/12/02
Posts: 13073
Location:Stuttgart, Germany
Can you reproduce the error when you enter that search term?
The SQL query is missing the table name. The introtext/bodytext looks like this would be related to stories, but I'd doubt that we have such a glaring bug there. Could this come from a plugin that's making use of stories?
bye, Dirk
The SQL query is missing the table name. The introtext/bodytext looks like this would be related to stories, but I'd doubt that we have such a glaring bug there. Could this come from a plugin that's making use of stories?
bye, Dirk
29
23
Quote
James
Anonymous
Hi Dirk,
I can't reproduce the issue my self, but I see it continuously in the logs. This is on the mac os x hints site, which we upgraded a few weeks ago. I did the upgrade for them, with Robs input.
Here are more lines from just an hour ago:
Mon 24 May 2010 05:45:54 PDT - 256 - An SQL error has occurred. Please see error.log for details. @ /web/macosxhints.com/system/databases/mysql.class.php line 261
The plugins in the plugins folder:
calendar
captcha
commentsfeeds
links
polls
rating
spamx
staticpages
xmlsitemap
I can't reproduce the issue my self, but I see it continuously in the logs. This is on the mac os x hints site, which we upgraded a few weeks ago. I did the upgrade for them, with Robs input.
Here are more lines from just an hour ago:
Text Formatted Code
Mon 24 May 2010 05:45:54 PDT - 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 '%') AND (title LIKE '%safari%' OR introtext LIKE '%safari%' OR bodytext LIKE '%s' at line 1. SQL in question: SELECT COUNT(*) FROM%') AND (title LIKE '%safari%' OR introtext LIKE '%safari%' OR bodytext LIKE '%safari%')) Mon 24 May 2010 05:45:54 PDT - 256 - An SQL error has occurred. Please see error.log for details. @ /web/macosxhints.com/system/databases/mysql.class.php line 261
The plugins in the plugins folder:
calendar
captcha
commentsfeeds
links
polls
rating
spamx
staticpages
xmlsitemap
23
16
Quote
James
Anonymous
No thoughts on this issue?
19
20
Quote
Status: offline
Dirk
Site Admin
Admin
Registered: 01/12/02
Posts: 13073
Location:Stuttgart, Germany
I had a look through the code and to me this doesn't look like it's an SQL request produced by Geeklog. But since it doesn't happen all the time, I may have missed something, so I've asked Sami for a second opinion. He's travelling this week though, so it may take a few days for him to get back to us.
It would help if you could find a way to reproduce the error.
bye, Dirk
It would help if you could find a way to reproduce the error.
bye, Dirk
24
18
Quote
Status: offline
sbarakat
Forum User
Junior
Registered: 04/22/08
Posts: 27
Location:Norwich, United Kingdom
Quote by: James
Mon 24 May 2010 05:45:54 PDT - 256 - An SQL error has occurred. Please see error.log for details. @ /web/macosxhints.com/system/databases/mysql.class.php line 261
As Dirk mentioned it does look like it fails searching the stories of the site. But I think there are two terms being used here. If I match it up against a SELECT statment that works (alignment may be a bit out)
Text Formatted Code
Mon 24 May 2010 05:45:54 PDT - 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 '%') AND (title LIKE '%safari%' OR introtext LIKE '%safari%' OR bodytext LIKE '%s' at line 1. SQL in question: SELECT COUNT(*) FROM%') AND (title LIKE '%safari%' OR introtext LIKE '%safari%' OR bodytext LIKE '%safari%')) Mon 24 May 2010 05:45:54 PDT - 256 - An SQL error has occurred. Please see error.log for details. @ /web/macosxhints.com/system/databases/mysql.class.php line 261
Text Formatted Code
SELECT COUNT(*) FROM%') AND (title LIKE '%safari%' OR introtext LIKE '%safari%' OR bodytext LIKE '%safari%'))SELECT ... FROM ... WHERE ... AND ((title LIKE '%safari%' OR introtext LIKE '%safari%' OR bodytext LIKE '%safari%'))
So it would appear the search term is something along the lines of "... FROM safari," testing this on geeklog.net causes an error. I've just commited a patch that should fix the issue.
16
23
Quote
All times are EST. The time is now 09:12 am.
- Normal Topic
- Sticky Topic
- Locked Topic
- New Post
- Sticky Topic W/ New Post
- Locked Topic W/ New Post
- View Anonymous Posts
- Able to post
- Filtered HTML Allowed
- Censored Content