我想按月计算所有人数。现在它正在分组。
Select
TRUNC(ed.COVERAGE_START_DATE),
Count(Distinct Egpa.Person_Id)
答案 0 :(得分:0)
尝试:
SELECT Month, Count(Person)
FROM Table
GROUP BY month
OR
SELECT DATEPART(Month, YourDate) Month
FROM yourtable
GROUP BY DATEPART(Month, YourDate)