Do you have a "Person ID" or something of that sort, or just first and last name?
If it's just by name, then you can change the Partition By portion of the Row_Number function so it just gets each person once.
(If it's just by name, please consider redesigning the database, if you're in a position to do so. Otherwise, the moment you have two "John Smith"s in the database, all kinds of things will break.)
- Gus "GSquared", RSVP, OODA, MAP, NMVP, FAQ, SAT, SQL, DNA, RNA, UOI, IOU, AM, PM, AD, BC, BCE, USA, UN, CF, ROFL, LOL, ETC
Property of The Thread
"Nobody knows the age of the human race, but everyone agrees it's old enough to know better." - Anon