I have the following simple table, called TableA
ID SomeVal
1 10
1 20
1 30
2 40
2 50
3 60
I want to select only those rows where SomeVal is the smallest value for the same ID value. So my results should look like this:
1 10
2 40
3 60
I think I need Group By in my SQL but am not sure how. Thanks for your help.
1 Answer