Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 General SQL Server Forums
 New to SQL Server Programming
 Start at 100001

Author  Topic 

micky--4444
Starting Member

19 Posts

Posted - 2010-07-27 : 07:28:57
Hi,

Is it possible to start the autonumber at 100001, rather than 1?
Just I need users to have a 6 digit userid.

thanks,.

Sachin.Nand

2937 Posts

Posted - 2010-07-27 : 07:39:19
Yes it is possible.

declare @tbl as table(id int identity (10001,1),nm varchar(5))
insert into @tbl
select 'a'union all
select 'b'

select * from @tbl



Limitations live only in our minds. But if we use our imaginations, our possibilities become limitless.

PBUH
Go to Top of Page
   

- Advertisement -