Selecting values from table based on the date

Posted by Bulksms under ASP.NET on 10/22/2011 | Points: 10 | Views : 645 | Status : [Member] | Replies : 1
My table contains UserName, Date, Count.

UserName Date Count

Test 01-08-2011 1
Test 01-08-2011 2
Test 02-08-2011 1
Test 03-08-2011 5

Hi Friends,

I need to select the values based on the date with group by UserName and date.
Eg:

UserName 1 2 3 .....31

Test 3 1 5 ......

Here 1,2,3 .... indicates date.
2 1 1 ...... indicates count

Can anyone tell me the query for this.

Thanks in advance.
Kapsystem.




Responses

Posted by: Abdulhaknet on: 10/25/2011 [Member] Starter | Points: 25

Up
0
Down
hi friend ,


select userame,date,... from mytable group by username,date

Bulksms, if this helps please login to Mark As Answer. | Alert Moderator

Login to post response