Import database data

Use the task Import Database Data to copy delivery data to the database.

  1. Right-click your environment, and select Database > Import Database Data.
  2. Depending on the environment status:
    • If the environment is running, the message "Set M3BE environment in maintenance mode" is displayed. Click Next.

    • If the environment is stopped, the environment is started in maintenance mode.

      Note: 

      The environment is in maintenance mode until the application is stopped, started, or set online.

  3. Specify the database user login information:
    User

    mdbadm

    Password

    Enter the password for the user.

    Click Next.

  4. Select the default mode Import Database Data.

    The different configuration options works as follows:

    Import Database Data

    Select this option to import specific data.

    Import Database data using saved configuration

    Select this option to import specific data using a saved configuration.

    Note: 

    It is recommended to save the settings or configuration related to data that you frequently use, such as tables, to save you from providing the data again.

    Delete configuration

    Select this option to remove a saved configuration.

    When the second and third options are selected, the Load Configuration field is enabled. It allows you to use or delete a saved configuration. The configuration is stored in the LCM client workspace that you selected when you logged in. If you can not find your saved configuration, consider if you saved the configuration in another workspace, or in a workspace for another LCM Client.

  5. Select data zip files to import.
    Source zip files uploaded to LCM server

    Select the zip files to be added by selecting the check box to the left of the zip file name. It is possible to select several files at a time.

    Source zip files stored in local M3BE installation path

    Select the zip files to be added by selecting the check box to the left of the zip file name. It is possible to select several files at a time.

    Example for a market:

    /M3BE/_db_data/<Mxx>/15.1/delivery_data.zip

    Click Next.

  6. Select tables to import to database.
    Component

    Select the component specified in the Environment Configurator Components pane (MNS104).

    Database schema

    Depending on your selection of component, the correct schema is presented.

  7. Select the default mode Import all tables.

    The different table selections work as follows:

    Import all tables

    All tables will be imported

    Enter table name

    One specific table will be imported, enter the name in the text field.

    Select tables

    A selection of tables are presented in the box at the bottom of the dialog.

    Click Next.

  8. Select the import strategy "Copy tables without checking for duplicate keys".

    The different strategies work as follows:

    Replace existing records

    The records in target that have a duplicate in the source are replaced by the ones imported.

    Keep existing records

    The existing records in both source and target are left unchanged in the target.

    Copy tables without checking for duplicate keys

    All records will be inserted without checking for duplicate keys. This may cause an exception if records already exists.

    Note: 

    This option is recommended when the target database is empty, and in other situations when there is no risk of duplicate keys. This option increases the copy data performance significantly.

    Clear target tables before import

    For tables that exist in both source and target, data are cleared in target tables before import.

    Allow data mismatch

    Select this option to allow the format of the existing table and the imported tables to differ without causing any errors.

  9. Click Next.
  10. To save this configuration, specify a unique name, and click Next.
  11. On the Summary screen, verify the property values, and click Finish.
  12. When the task is finished, a dialog appears. Click OK. To view the log file, either click View log or go to the Logs view.