morepainot (7/26/2012)
The reason for the WHILE LOOP is because with CURSOR it is much slower than with WHILE LOOP.
Like I said, that's patently and absolutely not true. The WHILE LOOP is usually what makes cursor usage so slow and I've proven that many times for companies that think other wise.
The key to performance here is to get rid of the WHILE loop. Period.
--Jeff Moden
Change is inevitable... Change for the better is not.