Really simple example:
Let’s say I have this table:
ID Name
GUID1 John
GUID2 John
GUID3 John
GUID4 John
GUID5 Jane
GUID6 Jane
I would like to do a select which assigns a counter to every occurence of the same name (starting at 1 each time). i.e.:
ID Name Counter
GUID1 John 1
GUID2 John 2
GUID3 John 3
GUID4 John 4
GUID5 Jane 1
GUID6 Jane 2
So that the key (Name, Counter) forms a unique combination.
Thanks
Karl
1 Answer