Unable to perform sql
Posted: Mon Dec 09, 2019 2:43 pm
Hi, when I try to merge two tickets created by email, this error is returned:
SELECT COUNT(*) as `cnt`, (CASE WHEN `staffid` = 0 THEN 0 ELSE 1 END) AS `staffcnt` FROM `hesk_replies` WHERE `replyto`=35 GROUP BY `staffcnt` 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 'ASC' at line 1
What can this problem be due to?
Thank you,
A. Santoro
SELECT COUNT(*) as `cnt`, (CASE WHEN `staffid` = 0 THEN 0 ELSE 1 END) AS `staffcnt` FROM `hesk_replies` WHERE `replyto`=35 GROUP BY `staffcnt` 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 'ASC' at line 1
What can this problem be due to?
Thank you,
A. Santoro