T Sql While Loop Into A Temp Table For Final Output

T Sql While Loop Into A Temp Table For Final Output