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.

 All Forums
 General SQL Server Forums
 New to SQL Server Programming
 TIMEWISE QUERY

Author  Topic 

cutepraba
Yak Posting Veteran

53 Posts

Posted - 2012-07-13 : 00:52:35
I have a table that has a date on it.

I need to timewise totals

The results would be
12:01 Am 06:59 Am : 15
07:00 Am 12:59 Pm : 65
01:00 Pm 05:59 Pm : 34
06:00 Pm 11:59 Pm : 5

can i have the result without subquery?

____________
Praba

sql-programmers
Posting Yak Master

190 Posts

Posted - 2012-07-13 : 04:17:47
Hi,

Can you explain detail with example table with data.

SQL Server Programmers and Consultants
http://www.sql-programmers.com/
Go to Top of Page

visakh16
Very Important crosS Applying yaK Herder

52326 Posts

Posted - 2012-07-13 : 10:15:53
how is data present in table columns? is it existing as time or do you've date as well?

------------------------------------------------------------------------------------------------------
SQL Server MVP
http://visakhm.blogspot.com/

Go to Top of Page
   

- Advertisement -