• Row By Agonizing Row -- I'm surprised that you've never heard of it!

    For each row in Employees you have to run the query (select min(id) from Employees group by employeeid, employeeno)

    The set-based solution does this just one time and joins back to Employees to perform the deletes.

    You are right, you probably wouldn't notice any difference in performance on small tables, but I'd bet 20,000 rows would show a noticeable difference, and the difference in 1,000,000 plus row tables could be counted in minutes, maybe hours.