Sasi Reddy

Sasi Reddy

  • NA
  • 346
  • 226.8k

Query

Oct 13 2014 6:03 AM
select Month(Logintime) as Month,Year(Logintime) as Year,ID as ID ,cast(Logintime as time) as LoginTime from UserLoginStatus where UserId=15 and Logintime IS NOT NULL
Month    Year      ID   LoginTime
10            2014      4     15:05:10.5500000
10             2014      5     15:06:14.9170000
 
If i write above query i am getting the above result
 
But i need  
 

Answers (7)