Table of Contents:
Copy descriptions between repositories
Switch to the documentation for Dataedo 8.x (current).
You can copy documentation descriptions, modules, diagrams or user relations from one repository to other repsitory. This might be useful if you are using dev, UAT and prod environments or have multiple instances of the same or similar database.
For these scenarios we've created a script that copies descriptions between documentations - either in the same, or in different repositories.
The script won't work for file repositories.
To download, right click on the link below, and save:
What is copied
The script copies:
- Object (table, view, trigger, procedure, function, column, relation, unique key, parameter) desciptions, custom fields and titles.
- Optionally overwrites user-defined objects: relations, unique keys, modules, ER diagrams.
The script does not copy:
- schema (tables, columns etc.).
- cross database relations
- custom field settings
- manual tables
You need to make sure that database schema was imported (and updated) prior to running script.
Copying descriptions only
If you set @synch_user_obj parameter to 0 procedure will only copy descriptions, custom fields and titles.
Copying descriptions and user defined objects
If you set @synch_user_obj parameter to 1 then procedure will overwrite all user-defined objects relations, unique keys, modules, ER diagrams. Note that this will remove from the destination repository user defined object missing from source repository.
Running the script
The script is run on Dataedo repository database. You can connect to it through SQl Server Management studio.
- Replace [source_repository] and [destination_repository] in the entire file with your source and destination repository database. If you want to copy description within a repository, replace both with the same database name.
- Change the @src_title and @dst_title variables to source and destination documentation names.
- Make sure the custom field names and settings on both sides are the same if you want them to be copied.
- Set the @synch_user_obj to 0 if you only want to copy descriptions of database objects, or 1 if you also want to copy user-defined objects.
Documentation names must be unique within repositories. Both documentations must exist. Script will not work if names can't be matched.