我在sql server ce中遇到令牌=错误
with temp
as
(
SELECT
ROW_NUMBER() over (ORDER BY BiilDate) AS Number
,BiilDate
, DATENAME(dw, BiilDate) as day
from
Bill
where
BiilDate >= DATEADD(day,-7,GETDATE())
AND
BiilDate < GETDATE()
)
SELECT
day
, COUNT() TotalCount
FROM
temp
GROUP BY
day
HAVING
COUNT() >= 1
ORDER BY
COUNT(*) desc
答案 0 :(得分:0)
Sql ce不支持CTE或row_number