Error text : SELECT COUNT(*) FROM (
SELECT
mgb.*,
mb.businessName,
mb.businessLinkName
FROM
mg_gamebusiness mgb
LEFT JOIN
mg_business mb
ON
mgb.businessId = mb.businessId
WHERE
mgb.gameId =
ORDER BY mgb.sorting ASC
) vt
Error Number : 1064
Error Message : 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 'ORDER BY mgb.sorting ASC
) vt' at line 14