Home | Print | Archive | Blog | Contact
A Newsletter for Unisys EAE and Agile Business Suite Clients | January 2019

Engineering Corner: Cloning an AB Suite Model Database

By Tomas Liu, AB Suite Developer Advocate, Unisys

Importing a large Agile Business Suite (AB Suite®) model can be a time-consuming process.

To simplify and shorten it, we recommend using a cloned model database instead of importing the model again. Following this method, all you’ll need to do is restore the backed-up database locally to set up your development environment. Below, we’ve outlined the steps you’ll need to follow to make this happen.

Backing Up the Model Database

Frist things first, you’ll want to create a backup copy of your model database. We recommend running the “SuitableForCloning.sql” script to make sure the database is a suitable source for cloning.

If no errors are detected, use the following steps to back up the model:

  • Open SQL Server Management Studio
  • Connect using an administrator account that also has a “sysadmin” role for the database
  • Double-click the server name in the “Object Explorer” pane to expand the server tree
  • Expand the “Databases” option in the “Object Explorer” pane
  • Right-click the model database you want to back up, then select “Tasks>Back up…” to display the “Back Up Database” dialog box
  • Go to the “Select a page” pane, choose “General,” and then:
    • Set the backup type to “Full”
    • Select “Disk” in the “Back up to” option
    • Choose the default back up destination, or click “Add…” to enter a new one
    • Click “OK”

Restoring the Model Database

Now that you’ve backed up the model, the next step is to restore it.

To do so on your SQL Server instance, you’ll need to:

  • Open SQL Server Management Studio
  • Connect using an account that has a “sysadmin” role on the chosen SQL Server instance
  • Double-click the server name in the “Object Explorer” pane to expand the server tree
  • Expand the “Databases” option in the “Object Explorer” pane
  • Right-click “Databases,” then select “Restore Database….” to display the “Restore Database”
    dialog box
  • Go to the “Select a page” pane, choose “General,” and then:
    • Select the “Device” radio button
    • Locate your model database backup file – note that you’ll need to copy the backup file from another machine if it isn’t available on yours
    • Click “OK” to restore the database

Initializing the Database

Once you’ve successfully restored the model database, you’ll need to run an additional script to initialize and configure it.

So, go to your restored model database, then perform the following:

  • Right-click the restored database in the “Object Explorer” pane, then select “New Query” to display a “SQL Query” editor window
  • Copy and paste the SQL Script found in “ConfigureAfterRestoring.sql” to the “SQL Query” editor window
  • Press “F5” to execute the SQL script that initializes and configures the database

And with that, you’re done! The cloned model database will now be ready for use.

Subscribe | Unisys.com | Comment | Newsletter Archive