我需要得到满足条件的 bug_idtimediff(delta_ts,creation_ts) > "00:01:00"
我用这个创建了查询
GROUP_CONCAT(
DISTINCT
bug_id
from bugs
where
timediff(delta_ts,creation_ts) > "00:01:00"
SEPARATOR ' '
)
请帮助,因为我在此查询中遇到错误:
select sum(IF(priority="P3",1,0)) P3count,
SUM(IF(priority="P2",1,0)) P2count,
sum(IF(timediff(delta_ts,creation_ts) > "00:01:00",1,0)) exeeded,
GROUP_CONCAT(DISTINCT bug_id from bugs where priority="P2")
from bugs
where bugs.product_id=237
and bugs.resolution='FIXED'
and bugs.creation_ts >='2013-06-14 09:00:00'
and bugs.creation_ts <= '2013-06-16 08:59:59'
and bug_status="RESOLVED";
投掷错误:
ERROR 1064 (42000): You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to usenear 'from bugs where priority="P2") from bugs where bugs.product_id=237 and bugs.res' at line 1