Originally posted by Srinivasa Raghavan:
I'm not sure whether it will work but did you try with distinct clause ?
SELECT DISTINCT MapId, Name FROM Table1.
That won't work because it is missing the subid in the resultset, and when you add that then you will not get the results you want.
Also, this looks like homework, so we want to give really good hints to help out, but not give the answer completely away. Like my hint really does give it a way in a MIN type of way.
Mark