Link to home
Start Free TrialLog in
Avatar of yanci1179
yanci1179

asked on

SQL 2008 R2 Getting first record that occurs

I have table with results similar to:

ID1  ID2
1      1
2      1
3      1
10    4
11    4
12    3
15    7
16    7
17    7
I want to only retrieve the first occurrence of ID2.   So I would like the results to be:

ID1  ID2
1       1
10     4
12    3
15    7

Thank you!
ASKER CERTIFIED SOLUTION
Avatar of Nem Schlecht
Nem Schlecht
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial