We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 40122
    • 330 Posts
    I just updated ModX 1.0.5 to 1.0.12 and am getting this error on the home page:

    « MODX Parse Error »
    MODX encountered the following error while attempting to parse the requested resource:
    « Execution of a query to the database failed - 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 sc.id IN (1,307,4,300,13,241,206,211,210,207,203,204,5,124,125,354,126,20' at line 1 »
    SQL > SELECT DISTINCT sc.id, sc.menutitle, sc.pagetitle, sc.introtext, sc.menuindex, sc.published, sc.hidemenu, sc.parent, sc.isfolder, sc.description, sc.alias, sc.longtitle, sc.type,if(sc.type='reference',sc.content,'') as content, sc.template, sc.link_attributes FROM `allclass_modx`.`modx_site_content` sc LEFT JOIN `allclass_modx`.`modx_document_groups` dg ON dg.document = sc.id WHERE sc.published=1 AND sc.deleted=0 AND (sc.privateweb=0) AND sc.hidemenu=0 AND sc.id IN (241') AND sc.id IN (1,307,4,300,13,241,206,211,210,207,203,204,5,124,125,354,126,202,6,14,15,16,21,19,24,18,22,20,17,25,23,26,27,28,219,220,221,226,224,229,223,227,225,222,230,228,231,232,233,235,234,236,237,246,247,248,253,251,256,250,254,252,249,257,255,258,259,260,262,261,263,264,38,39,40,45,43,48,42,46,44,41,49,47,98,99,100,102,101,103,104,50,51,52,57,55,60,54,58,56,53,61,59,105,106,107,108,109,110,112,111,113,114,115,116,117,118,119,120,121,122,123,74,75,76,81,79,84,78,82,80,77,85,83,301,86,292,197,318,316,315,314,317,133,214,216,238,217,218,215,212,213,7,8,306,62,273,63,269,268,271,270,272,64,69,67,72,66,70,68,65,73,71,277,9,278,279,10,11,308,344,360,309,281,284,283,328,290,282,285,286,291,287,288,289,280,302,303,304,12,294,296,305,127,130,131,129,128,132,134,349,361,275,362,359,358,357,355,352,326,330,135,364,146,350,363,312,183,334,193,189,343,184,311,139,140,138,142,295,2,3) GROUP BY sc.id ORDER BY sc.menuindex ASC ;


    Which looks to be caused by Wayfinder. Tried downgrading Wayfinder to no avail.

    Does this mean I am running a old version of MySQL? I am trying to find the System Requirements for Evo but the link on the site only shows the ones for Revo.

    Can anyone help me out?

    Thanks
      • 9995
      • 1,613 Posts
        Evolution user, I like the back-end speed and simplicity smiley
      • AND sc.id IN (241') 


        Looks like you have a closing ' instead of ` in the Wayfinder includeDocs parameter.
          • 40122
          • 330 Posts
          Quote from: Jako at Nov 12, 2013, 02:33 PM
          AND sc.id IN (241') 


          Looks like you have a closing ' instead of ` in the Wayfinder includeDocs parameter.

          Good spotting.

          That seems like an issue with the Wayfinder files them selves. Is there a way I can fix this without digging through the guts of it?
          • Could you please post your wayfinder call?
              • 40122
              • 330 Posts
              Quote from: Jako at Nov 13, 2013, 10:37 AM
              Could you please post your wayfinder call?

              Nothing special:

              [[Wayfinder? startId=`0` &level=`2` ]]
              • Sorry, I don't believe that:

                This line
                AND sc.id IN (241')


                is generated by
                			//add the include docs to the where clause
                			if ($this->_config['includeDocs']) {
                				$menuWhere .= " AND sc.id IN ({$this->_config['includeDocs']})";
                			}


                And there are no lines in the snippet code that are generating any value in $this->_config['includeDocs'] if the parameter is not set.

                I has to be another Wayfinder call on the page or another snippet that generates almost the same SQL query as Wayfinder.