server2012表格怎么樣設置標識?
1.在創建表的時候就設置標識列
CREATE TABLE [dbo].[Table1]( [column1] [int] IDENTITY(1,1) primary key, [column2] [varchar](30) NOT NULL, [column3] [datetime] NULL )2.插表時打開標識插入與關閉標識輸入
Set IDENTITY_INSERT DB.dbo.Table1 ON
Set IDENTITY_INSERT DB.dbo.Table1 OFF