identity property

  • After restoring a database (2000) onto 2005, we noticed that the identity property is missing on all our tables. Is there a way to set this on all tables other than using GUI.

    Thanks.

    R

  • may be u can script the tables and run in sql 2005.But if u have many tables its not advisable.Ur question seems to be unique.Generally it will not happen..Pls do let me know if any better solution is available.

    Cheers

    Deepak

    [font="Verdana"]- Deepak[/font]

  • The only option that I changed was Compatibility Level to SQL Server 2005 (90).

    Other thing that I noticed now is that, all the constraints and not being generated when trying to script a table. But, when I run sp_help 'tableName', the constraints are showing up.

  • Hi Ram,

              What u did is rite.We normally change the Compatability level to 90 after restoring sql 2000 db to sql 2005.But theres a few issues u can refer the below link.I think it will be helpful.

    http://www.innovartis.co.uk/topical/migratingto2005.aspx

    [font="Verdana"]- Deepak[/font]

  • Found the cause, the database restore worked fine. There was a replication that was turning the identity property (on 2005) to off. So we basically turned off the replication for now.

    Is there a way to change option for a column with identity property for NOT FOR REPLICATION?

    Thanks Deepak.

Viewing 5 posts - 1 through 4 (of 4 total)

You must be logged in to reply to this topic. Login to reply