How to alter column to identity(1,1)

Home Forums Database Sql Server How to alter column to identity(1,1)

This topic contains 0 replies, has 1 voice, and was last updated by  Ankur 6 years, 7 months ago.

Viewing 1 post (of 1 total)
  • Author
    Posts
  • #3246

    Ankur
    Moderator

    You can’t alter the existing columns for identity.

    There are two methods which you can use to Alter Column as Identity-

    1. Create a new table with identity & drop the existing table

    2. Create a new column with identity & drop the existing column

    if your table is not blank then before drop the table you need to first copy data in temp table.

Viewing 1 post (of 1 total)

You must be logged in to reply to this topic.