Freigeben über


How to: Synchronize the Tenant Database with the Application Database

This topic describes how to synchronize the business data (tenant) database schema with the application database in either a single tenant (non-multitenant) or multitenant deployment environment. You can synchronize the database from the Microsoft Dynamics NAV Development Environment or by using the Sync-NAVTenant cmdlet in the Dynamics NAV Administration Shell.

Synchronize database from the development environment

  1. Open development environment as an administrator.

  2. On the Tools menu, choose Sync. Schema For All Tables, and then choose With Validation and follow the schema synchronization instructions.

Synchronize database with the Sync-NAVTenant cmdlet

  1. On the computer that is running the Microsoft Dynamics NAV Server, run Dynamics NAV Administration Shell as an Administrator.

    1. Choose Start, in the Search box, type Dynamics NAV Administration Shell.

    2. Right-click the related link, and then choose Run as Administrator.

  2. At the command prompt, type one of the following commands:

    • If the Microsoft Dynamics NAV Server instance is not configured to be a multitenant instance:

      Sync-NAVTenant –ServerInstance <ServerInstanceName>  
      
    • If the Microsoft Dynamics NAV Server instance is configured to be a multitenant instance:

      Sync-NAVTenant –ServerInstance ServerInstanceName -Tenant TenantId  
      

      Change the following parameter values.

      Parameter Description
      NAVServerInstance Specifies the Microsoft Dynamics NAV Server instance.
      TenantId Specifies the ID of the tenant.
  3. Press Enter to run the cmdlet.

See Also

Synchronizing Table Schemas
Converting a Database.md
Upgrading the Database
Multitenant Deployment Architecture