Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
Author |
Topic |
shagil.a.gopinath
Starting Member
14 Posts |
Posted - 2013-12-09 : 08:40:50
|
Table DateField--------------CNT-1 CNT-2 CNT-32013-12-09 09:00:00.000 8 1 22013-12-09 09:01:00.000 3 7 12013-12-09 09:02:00.000 1 2 32013-12-09 09:03:00.000 2 5 22013-12-09 09:04:00.000 1 1 72013-12-09 09:05:00.000 2 3 2My requirement is to get the output in the following format if i take the time with 2 minutes difference DateField ------------------ Sum-CNT-1 Sum-CNT-2 Sum-CNT-309:00:00.000 - 09:02:00.000 12 10 609:02:00.000 - 09:04:00.000 3 6 9Is there anyway i can write down a query to get the sum of the counter with 2 minutes difference. I may take time slot between 9 AM to 10 AM so i should get the sum of the counter with 2 minutes gap in a single query. Is it possible Thanks & Regards |
|
visakh16
Very Important crosS Applying yaK Herder
52326 Posts |
|
|
|
|