|
|
Select top n rows using a column for grouping and a different column as selection criteria. |
|
onDevelopment+=1;
|
By Javier Callico on
7/27/2007
|
|
|
Today I was asked to look into an interesting task that was keeping busy one of my colleagues for a while. It's such a common task that I'm wondering how come I was never presented with something similar before.
Let's use an example to better illustrate the task on hand. Imagine you have a notification system that runs daily and creates a list of different events for what individual users need to be notified.
This table represents the notification list resulted from the daily run:
UserId EventId ------------------- 1 1 & ...
|
 |
|
Comments (0)
|
More...
|
|
|
|
|
|
|