Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Add an unique id field in an existing table

Status
Not open for further replies.

mbwmbk

Programmer
Dec 12, 2002
19
0
0
US
I have a table with 100 rows. I need to add a unique id field to identify each row in the that table. How can I do that?
 
Use an alter table command then specify the IDENTITY attribute.

alter table << tablename >> add column << fieldname >> int not null identity _______________________________
regards,
Brian

AOL IM: FreelanceGaines

AG00280_.gif
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top