SQL Server Express: Failed to add primary key after creating a database table

Posted by Syd on Stack Overflow See other posts from Stack Overflow or by Syd
Published on 2010-06-07T23:08:09Z Indexed on 2010/06/07 23:12 UTC
Read the original article Hit count: 155

Scenario: I have created a database table. And when I tried to add a primary key (using the SQL Server Management Studiio) to the table, it failed with an error message "Saving changes is not permitted. The changes you have made requrie the following tables to be dropped and re-created. You have either made changes to a table that can't be recreated or enabled the option Prevent savign changes that require the table to be re-created."

The environment is Windows 7.

I have earlier installed it on a Windows XP SP2 and it worked.

And yes, my table is empty (freshly created).

My current workaround is to run the "Drop and Create" script. The other alternative is to create the primary key before I save the table.

Is this a bug or a limitation with the Express version?

© Stack Overflow or respective owner

Related posts about sql-server

Related posts about sql-server-express