Announcement

Collapse
No announcement yet.

Data Base Error Help me

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • [Forum] Data Base Error Help me

    Aslam-o-Alikum All.

    Respected Seniors, i m getting an isue. i just update my Vbulletin to 4.2, and now when i try to merge two threads then i get this error


    Code:
    Database error in vBulletin 4.2.0:
    
    
    Invalid SQL:
    DELETE FROM activitystream
                WHERE
                    typeid = 
                        AND
                    contentid IN (SELECT postid FROM post WHERE threadid IN (24188,24084));
    
    
    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 'AND
                    contentid IN (SELECT postid FROM post WHERE threadid IN (24188,24084))' at line 4
    Error Number  : 1064
    Request Date  : Tuesday, June 5th 2012 @ 10:43:27 AM
    Error Date    : Tuesday, June 5th 2012 @ 10:43:28 AM
    Script        : http://www.*****.com/forum/inlinemod.php?do=domergethreads&threadids=24188,24084
    Referrer      : http://www.****.com/forum/login.php?do=login
    IP Address    : 
    Username      : Mr hamza
    Classname     : vB_Database
    MySQL Version : 5.0.95
    so kindly help me.... how can i remove this error...... while mergeing two threads

    waiting for your kind reply

  • #2
    try to disable plug-ins first .

    i think its an issue with one of your hacks.

    Comment


    • #3
      It's happening because of this issue.

      Comment


      • #4
        Indeed, it's a known issue when the CMS isn't installed. If you remove this code in vb/activitystream/populate/forum/thread.php, the error will go away.

        PHP Code:
        $typeid vB::$vbulletin->activitystream['cms_comment']['typeid'];
                
        // delete CMS data (just in case)
                
        vB::$db->query_write("DELETE FROM " TABLE_PREFIX "activitystream
                    WHERE
                        typeid = 
        {$typeid}
                            AND
                        contentid IN (SELECT postid FROM " 
        TABLE_PREFIX "post WHERE threadid IN (" implode(","$threadids) . "))
                "
        ); 

        Comment


        • #5
          MAthew and Thunderbird thanks for your kind reply

          isue is resolved i just add
          /* and */ code to disable this code and my all errors are fixed. but now i m facing a new one error. after upgrading. my schedual task leave to work. last day my session table was fulled to 16Mb and site was failed to open then i empty the session table. then i notice my schedule task are not working

          my scheduled tasks are not working properly.

          Title----------------------------NextTime
          Process E-Mail Queue-------- 29-05-2012
          Activity Stream Popularity Update----29-05-2012
          Daily Statistics Log-----------------30-05-2012
          Hourly Cleanup------------30-05-2012

          what to do now?

          Comment


          • #6
            Originally posted by Matthew Gordon View Post
            Indeed, it's a known issue when the CMS isn't installed. If you remove this code in vb/activitystream/populate/forum/thread.php, the error will go away.

            PHP Code:
            $typeid vB::$vbulletin->activitystream['cms_comment']['typeid'];
                    
            // delete CMS data (just in case)
                    
            vB::$db->query_write("DELETE FROM " TABLE_PREFIX "activitystream
                        WHERE
                            typeid = 
            {$typeid}
                                AND
                            contentid IN (SELECT postid FROM " 
            TABLE_PREFIX "post WHERE threadid IN (" implode(","$threadids) . "))
                    "
            ); 
            Hmm so for forum only 4.2 this is the fix yes ? ... dont mean to be obvious but I aint gonna dick with some code on my setup without a definate from you guys ?
            www.plantandconstruction.co.uk

            Comment


            • #7
              Yes, removing that snippet of code from the file is the fix for now until a new version is released.


              Former vBulletin Support Staff
              Hacked recently? See my blog post "Recovering a Hacked vBulletin Site".
              Thinking outside the box? Need modification support? Visit www.vBulletin.org and have at it!

              Comment


              • #8
                Originally posted by faraz_hamza View Post
                MAthew and Thunderbird thanks for your kind reply

                isue is resolved i just add
                /* and */ code to disable this code and my all errors are fixed. but now i m facing a new one error. after upgrading. my schedual task leave to work. last day my session table was fulled to 16Mb and site was failed to open then i empty the session table. then i notice my schedule task are not working

                my scheduled tasks are not working properly.

                Title----------------------------NextTime
                Process E-Mail Queue-------- 29-05-2012
                Activity Stream Popularity Update----29-05-2012
                Daily Statistics Log-----------------30-05-2012
                Hourly Cleanup------------30-05-2012

                what to do now?
                Make sure this is still in your footer template.
                Code:
                	<!-- Do not remove cronimage or your scheduled tasks will cease to function -->
                	{vb:raw cronimage}
                	<!-- Do not remove cronimage or your scheduled tasks will cease to function -->

                Comment


                • #9
                  Originally posted by TheLastSuperman View Post
                  Yes, removing that snippet of code from the file is the fix for now until a new version is released.

                  Ok Thx guys thats definately cured it .. I tested plenty of post moving and all is good
                  www.plantandconstruction.co.uk

                  Comment

                  widgetinstance 262 (Related Topics) skipped due to lack of content & hide_module_if_empty option.
                  Working...
                  X