We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 27100
    • 4 Posts
    I call the following snippets: [[DropMenu]]

    and I get the following SQL 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 ’ASC’ at line 5 »
    SQL: SELECT DISTINCT sc.id,sc.pagetitle,sc.description,sc.isfolder,sc.parent,sc.alias,sc.published,sc.longtitle,sc.menutitle,sc.hidemenu,sc.introtext,sc.content_dispo,sc.contentType,sc.type,sc.template FROM `db153009386`.modx_site_content sc LEFT JOIN `db153009386`.modx_document_groups dg on dg.document = sc.id WHERE sc.parent = ’8’ AND sc.published=1 AND sc.deleted=0 AND (sc.privateweb=0 OR dg.document_group IN (2,3,4)) ORDER BY sc. ASC;

    --> The ORDER BY is missing ?!?

    any idea why this happens???
      • 27100
      • 4 Posts
      Found the solution

      I was already using a modified version to display my left menu (it uses <a> rather than <ul>)

      the real dropdown menu was calling the <a> function, so the variables needed where different... I simply renamed one of the function and that fixed the problem...