Announcement

Collapse
No announcement yet.

Database error in vBulletin 4.0.4 /vb/content

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

  • [CMS] Database error in vBulletin 4.0.4 /vb/content

    PHP Code:
    Database error in vBulletin 4.0.4:

    Invalid SQL:
    SELECT node.nodeid , (node.nodeleft 1) AS isrootnode.contenttypeidnode.contentidnode.urlnode.parentnode,
                    (CASE 
    WHEN node.contenttypeid =  THEN node.styleid ELSE parent.styleid end ) AS styleidnode.userid,
                        (CASE 
    WHEN node.contenttypeid =  THEN node.layoutid ELSE parent.layoutid end ) AS layoutid,
                        
    node.publishdatenode.setpublishnode.issectionnode.permissionsfromnode.nodeleftnode.noderight,
                        
    node.useridnode.showtitlenode.showusernode.showpreviewonlynode.lastupdatednode.showallnode.showrating,
                        
    node.showupdatednode.showviewcountnode.showpublishdatenode.settingsforbothnode.includechildrennode.editshowchildren,
                        
    parent.permissionsfrom as parentpermissionsnode.publicpreviewnode.comments_enablednode.shownav,
                        
    node.hiddennode.nosearch info.descriptioninfo.titleinfo.html_titleinfo.viewcountinfo.creationdateinfo.workflowdateinfo.keywords,
                        
    info.workflowstatusinfo.workflowcheckedoutinfo.workflowlevelidinfo.associatedthreadidinfo.creationdatenode.showrating,
                        
    info.ratingnuminfo.ratingtotalinfo.rating,
                        
    user.usernamethread.replycountsectionorder.displayorder 
                        
                    FROM cms_node 
    AS node
                    INNER JOIN cms_nodeinfo 
    AS info ON info.nodeid node.nodeid
                    LEFT JOIN user 
    AS user ON user.userid node.userid
                    LEFT JOIN thread 
    AS thread ON thread.threadid info.associatedthreadid
                    LEFT JOIN cms_sectionorder 
    AS sectionorder ON sectionorder.sectionid node.parentnode
                        
    AND sectionorder.nodeid node.nodeid
                    LEFT JOIN cms_node 
    AS parent ON parent.nodeid node.parentnode 
                    
                    WHERE node
    .nodeid 1;

    MySQL Error   You have an error in your SQL syntaxcheck the manual that corresponds to your MySQL server version for the right syntax to use near 'THEN node.styleid ELSE parent.styleid end ) AS styleid, node.userid,
                        (CASE ' 
    at line 2
    Error Number  
    1064
    Request Date  
    FridayJune 25th 2010 06:10:59 PM
    Error Date    
    FridayJune 25th 2010 06:10:59 PM
    Script        
    http://www.al3ial.com/vb/content/
    Referrer      http://www.al3ial.com/
    IP Address    111.11.11.1
    Username      
    admin
    Classname     
    vB_Database
    MySQL Version 
    5.0.90-community-log 

    PHP Code:
    Database error in vBulletin 4.0.4:

    Invalid SQL:
    SELECT node.nodeidnode.urlnode.parentnodenode.nodeleftnode.noderight,
                
    node.setpublishnode.publishdateinfo.titlenode.permissionsfromnode.hiddenCOUNT(child.nodeid) AS children,
                  
    SUM(CASE WHEN (child.setpublish AND child.publishdate 1277478782 AND child.contenttypeid <> ) THEN 1 ELSE 0 END) AS publish_count
                FROM cms_node 
    AS node
                LEFT JOIN cms_node 
    AS child ON child.parentnode node.nodeid AND child.new != 1
                LEFT JOIN cms_nodeinfo 
    AS info ON info.nodeid node.nodeid
                WHERE 
    (node.contenttypeid = )
                
    GROUP BY node.nodeidnode.urlnode.parentnodenode.nodeleftnode.noderight,
                
    node.setpublishnode.publishdateinfo.titlenode.permissionsfromnode.hidden 
                ORDER by node
    .nodeleft;;

    MySQL Error   You have an error in your SQL syntaxcheck the manual that corresponds to your MySQL server version for the right syntax to use near ') THEN 1 ELSE 0 END) AS publish_count
                FROM cms_node AS node
                LEFT JOIN cm' 
    at line 3
    Error Number  
    1064
    Request Date  
    FridayJune 25th 2010 06:13:02 PM
    Error Date    
    FridayJune 25th 2010 06:13:02 PM
    Script        
    http://www.al3ial.com/vb/admincp/cms_content_admin.php?do=list
    Referrer      http://www.al3ial.com/vb/admincp/index.php?do=nav
    IP Address    111.11.11.1
    Username      
    admin
    Classname     
    vB_Database
    MySQL Version 
    5.0.90-community-log 
    Foreign Man ..!

  • #2
    Help me ,,
    Foreign Man ..!

    Comment


    • #3
      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
      Seems to me you do not have the correct MySQL version for vBulletin...


      vB5 is unequivocally the best forum software, but not yet...

      Comment


      • #4
        Originally posted by beishe8 View Post
        Seems to me you do not have the correct MySQL version for vBulletin...

        sorry, but it was working before
        Foreign Man ..!

        Comment


        • #5
          What can I doing ?
          Foreign Man ..!

          Comment


          • #6
            Do you get that on every page of your CMS or only the home page?

            try going to yoursite.com/content/1/edit - can you get there?

            What do you have entered in vboptions > content management > default page - did you change that or leave it as default?

            Please don't PM or VM me for support - I only help out in the threads.
            vBulletin Manual & vBulletin 4.0 Code Documentation (API)
            Want help modifying your vbulletin forum? Head on over to vbulletin.org
            If I post CSS and you don't know where it goes, throw it into the additional.css template.

            W3Schools &lt;- awesome site for html/css help

            Comment


            • #7
              Originally posted by Lynne View Post
              Do you get that on every page of your CMS or only the home page?
              yes, on every page .


              Originally posted by Lynne View Post
              try going to yoursite.com/content/1/edit - can you get there?
              PHP Code:
              Database error in vBulletin 4.0.4:

              Invalid SQL:
              SELECT node.nodeid , (node.nodeleft 1) AS isrootnode.contenttypeidnode.contentidnode.urlnode.parentnode,
                              (CASE 
              WHEN node.contenttypeid =  THEN node.styleid ELSE parent.styleid end ) AS styleidnode.userid,
                                  (CASE 
              WHEN node.contenttypeid =  THEN node.layoutid ELSE parent.layoutid end ) AS layoutid,
                                  
              node.publishdatenode.setpublishnode.issectionnode.permissionsfromnode.nodeleftnode.noderight,
                                  
              node.useridnode.showtitlenode.showusernode.showpreviewonlynode.lastupdatednode.showallnode.showrating,
                                  
              node.showupdatednode.showviewcountnode.showpublishdatenode.settingsforbothnode.includechildrennode.editshowchildren,
                                  
              parent.permissionsfrom as parentpermissionsnode.publicpreviewnode.comments_enablednode.shownav,
                                  
              node.hiddennode.nosearch info.descriptioninfo.titleinfo.html_titleinfo.viewcountinfo.creationdateinfo.workflowdateinfo.keywords,
                                  
              info.workflowstatusinfo.workflowcheckedoutinfo.workflowlevelidinfo.associatedthreadidinfo.creationdatenode.showrating,
                                  
              info.ratingnuminfo.ratingtotalinfo.rating,
                                  
              user.usernamethread.replycountsectionorder.displayorder 
                                  
                              FROM cms_node 
              AS node
                              INNER JOIN cms_nodeinfo 
              AS info ON info.nodeid node.nodeid
                              LEFT JOIN user 
              AS user ON user.userid node.userid
                              LEFT JOIN thread 
              AS thread ON thread.threadid info.associatedthreadid
                              LEFT JOIN cms_sectionorder 
              AS sectionorder ON sectionorder.sectionid node.parentnode
                                  
              AND sectionorder.nodeid node.nodeid
                              LEFT JOIN cms_node 
              AS parent ON parent.nodeid node.parentnode 
                              
                              WHERE node
              .nodeid 1;

              MySQL Error   You have an error in your SQL syntaxcheck the manual that corresponds to your MySQL server version for the right syntax to use near 'THEN node.styleid ELSE parent.styleid end ) AS styleid, node.userid,
                                  (CASE ' 
              at line 2
              Error Number  
              1064
              Request Date  
              SundayJune 27th 2010 05:14:59 PM
              Error Date    
              SundayJune 27th 2010 05:15:00 PM
              Script        
              http://www.al3ial.com/vb/content/1/edit
              Referrer      
              IP Address    111.11.11.1
              Username      
              admin
              Classname     
              vB_Database
              MySQL Version 
              5.0.90-community-log 
              Originally posted by Lynne View Post
              What do you have entered in vboptions > content management > default page - did you change that or leave it as default?
              as default : 1-Index
              Foreign Man ..!

              Comment


              • #8
                I'm not sure what is up. I'd suggest putting in a support ticket.

                Please don't PM or VM me for support - I only help out in the threads.
                vBulletin Manual & vBulletin 4.0 Code Documentation (API)
                Want help modifying your vbulletin forum? Head on over to vbulletin.org
                If I post CSS and you don't know where it goes, throw it into the additional.css template.

                W3Schools &lt;- awesome site for html/css help

                Comment


                • #9
                  It looks like there's a problem with your content type table. Lynne is right, this is probably going to require some SQL queries to fix. In the ticket please include a phpMyAdmin login.
                  Please- I'm not tech support. Don't send your problem reports to me unless I've asked you to.

                  Comment


                  • #10
                    Any updates? What was the cause/fix?
                    <facepalm>

                    Comment


                    • #11
                      Can someone explain the fix/ cause? I just had this happen to me when I updated to 4.0.5. No problem in 4.0.4??

                      Comment


                      • #12
                        You appear to either have some missing files or an error in your database. Probably an invalid entry in the contenttype table. Please clear the cache, re-upload your latest files, and if it persists create a support ticket.
                        Please- I'm not tech support. Don't send your problem reports to me unless I've asked you to.

                        Comment


                        • #13
                          I know what is causing this error.
                          See for this line U don't have any contenttypeid.
                          CASE WHEN node.contenttypeid =

                          This is caused when your content table in VB database has no entries for
                          the contentype.

                          Solution is to add proper data to contenttype table.

                          May be someone who is using the CMS can give u the data.

                          Check for the data in the table. if that is correct, then you need to flush your cache and all.

                          I am also having this same problem and trying to fix it. If you have got it fixed, please post the solution

                          Comment


                          • #14
                            Can any one please post the Content and Schema of Contenttype table?

                            Comment


                            • #15
                              I was having same error in BLOGS. SO I got the insert statements from UPDATE Files and fired these two queries.

                              INSERT INTO `target_forum`.`vb_contenttype` ( `contenttypeid` ,
                              `class` ,
                              `packageid` ,
                              `canplace` ,
                              `cansearch` ,
                              `cantag` ,
                              `canattach` ,
                              `isaggregator`
                              )
                              VALUES ( NULL , 'BlogEntry', '2', '0', '1', NULL , '1', '0'
                              ), ( NULL , 'BlogComment', '2', '0', '1', NULL , '0', '0'
                              );



                              I GUESS Its necessary to have The contenttypeid of Blogs related items as 15 and 16
                              and contenttypeid of CMS related items shuld be 17 and 18 (as the code suggests)

                              Comment

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