0
我有一张表,其中数据将每隔15分钟插入一次。所以时间戳将作如下如何使用sql server获取两个时间戳之间的数据
表名称:tblresultset
ID Date count
1 2017-05-03 1:15:00 10
2 2017-05-03 1:16:00 11
3 2017-05-03 1:27:00 2
4 2017-05-03 1:28:00 3
5 2017-05-03 1:29:00 6
6 2017-05-03 1:30:00 8
7 2017-05-03 1:31:00 2
8 2017-05-03 1:32:00 1
9 2017-05-03 1:33:00 2
Now I am looking for the query which will get me the total count from
2017-05-03 1:15 to 2017-05-03 1:30
我一定要得到这种计数在给定的日期,每次15分钟间隔。
请问有人能帮我吗?
你想'1:15'到'1:30',然后'1:30'到'1:45',....? – TriV
您是否在寻找特定的时间间隔(即017-05-03 1:15到2017-05-03 1:30),还是您希望所有数据按15分钟的时间间隔进行分组? – FrankerZ