vBulletin database problem

Discussion in 'vBulletin' started by wiredwebworld, Apr 22, 2010.

  1. #1
    I recently upgraded my vBulletin from 3.8 to 4.0.2 stable version, but since last 2 days my forum is giving strange database errors every few minutes.

    The source is:
    Database error in vBulletin 4.0.2:
    
    Invalid SQL:
    
    			SELECT thread.threadid, thread.title, thread.lastpost, thread.forumid, thread.replycount, thread.postusername, thread.postuserid, thread.lastposter, thread.lastposterid, thread.dateline, thread.views, thread.visible, thread.open, user.usergroupid, user.displaygroupid 
    			FROM vb_thread AS thread
    			LEFT JOIN vb_user AS user ON (user.userid = thread.lastposterid)
    			WHERE NOT ISNULL(thread.threadid) AND thread.visible = '1' AND thread.open!='10'  AND thread.forumid NOT IN(52,23,)
    			ORDER BY lastpost DESC
    			LIMIT 0, 10;
    
    MySQL Error   : 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 ')
    			ORDER BY lastpost DESC
    			LIMIT 0, 10' at line 4
    
    Code (markup):
    Could anyone please guide me fix this error?
    Thanks in advance
     
    wiredwebworld, Apr 22, 2010 IP
  2. digitalpoint

    digitalpoint Overlord of no one Staff

    Messages:
    38,334
    Likes Received:
    2,613
    Best Answers:
    462
    Trophy Points:
    710
    Digital Goods:
    29
    #2
    What is the page you are getting the error exactly? It's trying to query for an empty forumid...

    The query is looking for threads from forumid 52, 23 and then a null one (that's the problem).
     
    digitalpoint, Apr 22, 2010 IP
  3. maddyvong

    maddyvong Peon

    Messages:
    2
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #3
    ITS A DATA BASE ERROR once u reinstall the database sql and see ?
    ____________________________________________________
    Raw foods | super foods
     
    maddyvong, Apr 22, 2010 IP
  4. wiredwebworld

    wiredwebworld Peon

    Messages:
    79
    Likes Received:
    2
    Best Answers:
    0
    Trophy Points:
    0
    #4
    Thanks Shawn, actually i don't know which page is yielding the error.
    When i log on to the homepage, its giving this error sometimes.

    How do i rectify this?
     
    wiredwebworld, Apr 22, 2010 IP
  5. digitalpoint

    digitalpoint Overlord of no one Staff

    Messages:
    38,334
    Likes Received:
    2,613
    Best Answers:
    462
    Trophy Points:
    710
    Digital Goods:
    29
    #5
    Looks like some addon you have installed since that query isn't part of vBulletin's default install.
     
    digitalpoint, Apr 22, 2010 IP
  6. wiredwebworld

    wiredwebworld Peon

    Messages:
    79
    Likes Received:
    2
    Best Answers:
    0
    Trophy Points:
    0
    #6
    Yeah, i have few additional mods installed on the forum. Will disable them and check for few hours.
     
    wiredwebworld, Apr 22, 2010 IP