有桌子
id|date|somefield
我需要计算一年中每一天的条目数
select EXTRACT (DAY_OF_YEAR FROM date) as day, id from table
工作正常
但是当我尝试
select EXTRACT (DAY_OF_YEAR FROM date) as day, count(*) from table
失败
select count(*) from table group by EXTRACT (DAY_OF_YEAR FROM date)
也失败了