Problem with Identity Specification in SQL…

Error message when changing the identity column to “Yes” and save the changes:

“Saving changes is not permitted. The changes you have made require the following tables to be dropped and re-created. You have either made changes to a table that can’t be re-created or enabled the option Prevent saving changes that require the table to be re-created.”

It’s not a bug. It’s a safety measure added to SQL 2008’s management studio to indicate that the change that you’ve requested to the table requires that the table be dropped and recreated.

It’s there so that people don’t ‘accidentally’ make changes in production that will take hours.

use “SET IDENTITY_INSERT” command, for more info, see SQL BOL.

Or turn off the warning under tools–>options–>designers–>table and database designers

uncheck prevent saving changes that require table re-creation

Deixe uma resposta

O seu endereço de email não será publicado. Campos obrigatórios marcados com *