Comparing Changes using Complete Compare

You can compare your model with database, script, or another local model to check for differences using the Complete Compare wizard. Based on the results, you can then resolve or merge differences. Thus, maintaining a consistent model and database.

This topic walks you through the steps to compare an ArangoDB model with database.

To compare models with database:

  1. Open your ArangoDB model.

    Ensure that you are in the Physical mode.

    For example, the following image uses an ArangoDB model with 42 collections.

  2. Click Actions > Complete Compare.
    By default, the Complete Compare wizard assigns the open model as the Left Model. Hence, the Right Model tab appears.

  3. Click Database/Script.
    By default, the Allow Demand Loading option is selected.

  4. Click Load.
    The New Model dialog box appears. This starts the reverse engineering process to pull a model from the database to compare.

  5. Ensure that the Database is set to the correct one. In this case, ArangoDB. Then, click Next.
    The Reverse Engineer Process Wizard appears.

  6. Click Database. Then, click Next.
    The Connection tab appears. Use this tab to connect to the database from which you want to reverse engineer the model.

  7. After connection is established, click Next.
    The Databases tab appears. It displays a list of available databases.

  8. Under Available Databases, select the databases that you want to reverse engineer. Then, click .
    This moves the selected databases under Selected Databases.

  9. Click Next and on the Collection tab, click .
    This selects all the available collections. Also, ensure that the Document Count/Document % is not set to zero (0).

  10. Click Next and on the Option Set tab, keep the default configuration.

  11. Click Next and on the Detailed Options tab, keep the default configuration.

  12. Click OK.
    The reverse engineering process starts. Once the process is complete, the Right Model is set to the one that you reverse engineered.

  13. Click Next and on the Type Selection tab, select the appropriate options.

    For example, the following image shows the default options.

  14. Click Next and on the Left Object Selection tab, select the appropriate options.

    For example, the following image shows the default options.

  15. Click Next and on the Right Object Selection tab, select the appropriate options.

    For example, the following image shows the default options.

  16. Click Compare.
    The comparison process runs, and the Resolve Differences dialog box appears. It displays the differences between your model and database.
    For example, the following image shows that the frenchCity collection is available in your model but not in the database.

    Select the frenchCity collection and click . This will move the frenchCity collection to the right model (from the database). Similarly, resolve other differences.

  17. As differences were moved to the right model, click .
    This launches the Forward Engineering Alter Script Generation Wizard.

  18. Click Option Selection and clear all the Drop check boxes.

  19. Click Collection Filter and select or verify the collections to be included on the forward engineering script.

  20. Click Preview to view and verify the alter script.

  21. Click Generate and connect to your ArangoDB database.
    The forward engineering process starts. The script generates your physical database schema. You can access your database and verify the newly generated schema.

  22. Click OK. Then click Finish.
    This closes the Resolve Differences dialog box and displays the Complete Compare wizard.

  23. Click Close.