Changing the schema of a replicated database
Schema changes cannot be replicated. To change the schema of a replicated database, the SQL Server administrator must disable replication for all sites while you update the database template at each site. After you apply the changes at each site, the SQL Server administrator must to reconfigure replication. For this procedure, all Subscribers must be connected to the Publisher.
About this task
The different stages of the operation are:
- Preparing a new database template with the wanted schema (you need to work on a test database). When the new template is ready, you load the new template into your production database by using the File Manager - replication automatically distributes it to all sites.
- Preparing the database so that replication can be disabled. This involves taking the database offline (to prevent further conflicts from occurring) and then reviewing all existing conflicts. After this is done the SQL Server administrator disables replication by deleting the publication and its subscriptions.
- Applying the new schema at all sites. Only changes to entity types, link types, fields, standard fields, code lists, semantic types, datasheets, and common folder objects are applied.
- After the new schema is applied, the SQL Server administrator reconfigures replication.
Note: Although the changes to the database schema are not discarded, they
cannot be replicated. Changing the schema in this way, can also prevent you from
using File Manager and Update Database
Schema to update the schema as described in the following
information.
- What is a schema change?
-
Any of the following changes to the database design constitutes a schema change (and are not replicated):
- Adding, modifying, or deleting entity types, link types, fields or standard fields
- Adding, renaming, or deleting pick lists, icon lists, or Security Classification Code
listsNote: Adding or editing the description of the list is a schema change. Changing the content of these lists is not a schema change, and any changes you make to the contents are replicated.
- Adding, modifying, or deleting common folder objects
- Adding, modifying, or deleting datasheets
- Adding semantic types (whether manually or by loading a custom semantic type library) and assigning them
Do not delete anything from a database schema once the database is live.