Jump to content

In Sql Auto Increment


shyam

Recommended Posts

hello all,i want to crate a table which contain one AUTO_INCREMENT FIELD ,BUT i cant do that PLS HELP ME...I AM USING SQL SERVER 2005 :)

Link to comment
Share on other sites

SQL Server calls that an identity field, you need to make it an integer, not null, primary key, and in the properties panel make it an identity field.
hello sir,can YOU please tell me a query for below table or procedure to do socrate table tablenameid int,name varchar(20),and birthdate varchar(10)I WANT TO INCREMENT ""ID""thanks for last reply
Link to comment
Share on other sites

THANK YOU SIRTHANKU ALLI GOT THE ANSWER..........CREATE TABLE new_employees( id_num int IDENTITY(1,1), fname varchar (20), minit char(1), lname varchar(30))INSERT new_employees (fname, minit, lname)VALUES ('Krin', 'M', 'JREs')

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...