Manually updating the proxy databases

You can use the for proxy_update option with alter database to manually synchronize your proxy databases with their primary databases.. You must issue this command from the master database:

alter database <dbname>
    [existing options]
    [for proxy_update]

for proxy_update is useful for synchronizing changes to the primary databases that are not automatically migrated to the proxy databases. For example, if you rename the primary database using sp_rename, the proxy database is not automatically renamed. However, if you issue alter database... for proxy_update after renaming the database, the proxy database is rebuilt using the new database name.

If you enter for proxy_update with no other options (for example, alter database pubs2 for proxy_update), the size of the database is not extended; instead, the proxy tables are dropped from the proxy database and then re-created using the metadata from the primary companion’s database.

If you use alter database to extend the size of the database, the proxy table update is performed after the size extensions are made.

for proxy_update is supported for all external data sources, not only the primary companion in a cluster environment. Also, a database needs not be created with the for proxy_update clause for it to be manually updated. If you specify a default storage location, either through the create database command or sp_defaultloc, the primary companion’s metadata can be synchronized with the metadata at the remote storage location.

See the Reference Manual: Procedures.