SELECT tp.intPagesID, tdl.strTitle, td.intDocumentsID, td.intDocumentTypesID FROM tblPages AS tp, tblPages_lang AS tpl, tblDocuments AS td, tblDocuments_lang AS tdl WHERE (tp.intDocumentsID=td.intDocumentsID) AND (td.intDocumentsID=tdl.intDocumentsID) AND (tp.intParentPagesID=(SELECT intParentPagesID FROM tblPages WHERE intPagesID=)) AND (tp.intDeleted=0) AND (tp.intPagesID=tpl.intPagesID) AND (tpl.intLanguagesID=tdl.intLanguagesID) AND (tpl.intShowMenu=1) AND (tpl.intEnabled=1) AND (tdl.intLanguagesID=) ORDER BY tp.intOrder ASC
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 (tp.intDeleted=0) AND (tp.intPagesID=tpl.intPagesID) AND (tpl.intLanguage' at line 1