hi, Well based on your last post I have more clear your situation. It seems that you dont have increament column in table and i make fast solution,maybe is not the best solution but it will work. here is code down below,just copy-modify-paste and use in your real data create table #TempTable ( IdentValue int IDENTITY(1,1), Name1 varchar(255), Name2 varchar(255), ID Int ) insert into #TempTable select name1,name2,id from tabela declare @i as int set @i=0 declare @startValue as int set @startValue =2200 declare @endValue as int set @endValue=3200 while @i<(select count(*) from #temptable) begin set @i=@i+1 set @startValue=@startValue+1 update #tempTable set ID=@startValue where identValue=@i end delete from tabela insert into tabela select name1,name2,id from #temptable drop table #temptable select * from tabela
I Love T-SQL "Don't torture yourself,let the life to do it for you." If my post helps you kindly save my time by voting my post.