Welcome to Geeklog, Anonymous Wednesday, May 01 2024 @ 08:21 pm EDT

Geeklog Forums

Help with SQL errors please


simfin

Anonymous
Hi

I've tried to install 4 times .. and each with the same SQL errors. I'm on Mac OS X Server 10.2.8, MySQL 4.0.15 and PHP 4.3.3. The install seems to run fine, but when I go the main page I'm told there has been an SQL error. Here is what the error log says:

Sat Oct 25 12:00:46 2003 - 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 '= gl_comments.sid) AND
(gl_stories.perm_anon >= 2) AND (gl_stor. SQL in question: SELECT
DISTINCT count(*) AS dups, type, question, gl_stories.title,
gl_stories.sid, qid, max(gl_comments.date) as lastdate FROM gl_comments
LEFT JOIN gl_stories ON ((.sid = gl_comments.sid) AND
(gl_stories.perm_anon >= 2) AND (gl_stories.draft_flag = 0) AND (tid IN
('General','GeekLog'))) LEFT JOIN gl_pollquestions ON ((qid =
gl_comments.sid) A ND (gl_pollquestions.perm_anon >= 2)) WHERE
(gl_comments.date >= (DATE_SUB(NOW(), INTERVAL 172800 SECOND))) AND
((((gl_stories.perm_anon IS NOT NULL))) OR (((gl_pollquestions.perm_anon
IS NOT NULL)))) GROUP BY gl_comments.sid ORDER BY 7 DESC LIMIT 15

Could anyone decipher this for me please?

Thanks

simifn
 Quote

Status: offline

Dirk

Site Admin
Admin
Registered: 01/12/02
Posts: 13073
Location:Stuttgart, Germany
See here for previous coverage of this problem.

bye, Dirk
 Quote

simfin

Anonymous
Thank you very much Dirk. Setting 'hidenewcomments' to 1 did the trick.

I thought it might be somethng to do with it not having any comments .. but after adding some new comments and then setting hidenewcomments back to 0 it still showed the error. So I'll keep it set to 1.

Thanks again
 Quote

All times are EDT. The time is now 08:21 pm.

  • 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