SQL Compare 11

Deployment warnings

When the deployment wizard displays the Review page, you can click the Warnings tab to view any warnings about inefficiencies in the script, or reasons the script may fail.

The most common warnings that SQL Compare may display are summarized below. SQL Compare may also display warnings specific to SQL Server 2008 and SQL Server 2005 databases.

Table rebuild

To rebuild a table, SQL Compare drops the table and recreates it. SQL Compare creates a temporary table to store data so that data is not lost when the table is dropped.

SQL Compare rebuilds a table when:

  • a table's filegroup has changed

    You can ignore filegroups by selecting the Ignore filegroups, partition schemes, and partition functions project option. By default, filegroups are ignored.

  • a column cannot be altered

    For example, this warning is displayed if a column is to be changed from data type text to varchar.

  • a property of a column cannot be altered

    For example, this warning is displayed if a column is an identity in one database but not in the other.

  • the identity column on a table has changed

    For example, this warning is displayed if the seed has changed.

  • the column order on a table has changed

    This warning is displayed only if you select the Force column order in your project options and the order of columns in a table has changed. To ignore column order, clear the project option.

  • column x on table y must be added but has no default and does not allow NULL values

    If the table contains data, the deployment script will not work. To avoid this, add a default to the column in the source database, or set it to allow NULL values.

  • column x on table y must be added and does not allow NULL values; the default z must be bound to it

    A table in the source database contains an additional column that is set to NOT NULL, and has a default set.

Non-standard filegroups

You must create the filegroups manually before you perform the deployment. SQL Compare lists the filegroups that must be created.

  • You can ignore filegroups by selecting the Ignore filegroups, partition schemes, and partition functions project option. By default, filegroups are ignored.

Column will be truncated

For example, SQL Compare displays this warning when the length that is defined for the column has changed (such asvarchar(50) to varchar(30)).

This may result in loss of data.

Invalid cast

For example, SQL Compare displays this warning when:

  • a data type has changed from text to varchar
  • a user-defined data type has changed

In these cases, the deployment may fail.

Loss of precision or data

For example, SQL Compare displays this warning when the precision or scale of a decimal column has changed.

There may be loss of precision or data, or the deployment may fail.

Default password

If a user or application role must be created, SQL Compare displays details of the user or application role, and the default password that will be applied. The default password is p@ssw0rd.

Corrupt login

SQL Compare displays this warning when the login for a user is not defined. For example, when a database is restored, the association between users and logins is not preserved. To link a user to a login, you use sp_change_users_login. For more information, refer to your SQL documentation.

Statistics creation

Statistics will be created with default settings. You may need to modify the statistics manually.

No default value for column

The default value that is set in the source database will be applied where appropriate. If there is no default value, the update may fail.

Full-text information is being added to the database

The target database may not be full-text enabled (for example, because it has recently been restored from a backup). Ensure any full-text catalogs have been rebuilt on the target database before you run the script.

You can ignore full-text indexing by selecting Ignore full text indexing in your project options.

 


Didn't find what you were looking for?