I believe with MS SQL Server, Identity is an attribute to INT data type, hence, the following works

-- DDL
-- col of INT type without identity attribute
create table #tbl (col int primary key);

-- DDL
-- col of INT type with identity, default to 1,1 even without say Identity(1,1)
create table #tbl2 (col int identity primary key);

But this one won't
create table #tbl3 (col identity primary key);

>> Philip, I don't mean to be rude.  By the definition of
>> Primary Key, the [ID] can not be NULL, hence,
>> [ID] int identity Primary Key would do
>
>Actually, by definition an Indentity is an Int
>
>So "[ID] identity primary key" would do
>
>But if you want to get to the proper specifics, it should be
>
>[ID] int not null identity(1,1) primary key
>
>
>
[Todays Threads] [This Message] [Subscription] [Fast Unsubscribe] [User Settings]

Reply via email to