I have a table with records which include a datetime column "CreationDate".
I need to get the following information for every of the last 90 days:
- How many records were there in total in existence
- How many records were added on that day
I could do this through a loop of counting of course, but this would hit the database 90 times... is there a better way of doing this aggregate without having to riddle the DB with requests?
I'm using C#, LINQ, SQL Server 2008.