Skip Headers
Oracle® Warehouse Builder Installation and Administration Guide
11g Release 2 (11.2) for Windows and Linux

Part Number E10579-01
Go to Documentation Home
Home
Go to Book List
Book List
Go to Table of Contents
Contents
Go to Index
Index
Go to Master Index
Master Index
Go to Feedback page
Contact Us

Go to previous page
Previous
Go to next page
Next
View PDF

12 Using the Metadata Loader

This section discusses change and version management with Metadata Loader. The Metadata Loader utility copies and moves all types of metadata objects in a repository. With this utility, you can move metadata between Oracle Warehouse Builder repositories that reside on platforms with different operating systems. You can use the Design Center to run the Metadata Loader utilities. The Design Center provides a graphical interface that guides you through the process of exporting and importing metadata.

This section contains the following topics:

Exporting Metadata from the Design Center

You can use Design Center to export objects from a workspace into an MDL file. This includes objects that are part of the Project Navigator, Locations Navigator, and Globals Navigator. The information related to the exported objects, such as table columns and their constraints, data loading configuration parameters, and named attribute sets, are also exported.

Before you attempt to export metadata, ensure you have READ privileges on any object that you want to export. You also need to have READ privileges on folder objects. If you do not have READ privileges on a folder object, such as projects or modules, the folder object and all objects that it contains are not exported. During an export, the Metadata Export Utility skips objects for which you do not have READ privileges. It logs information about the list of objects that have not been exported due to lack of security privileges. See "Metadata Loader Log File" for details about viewing the list of objects that were not exported.

By default, READ privileges are provided on all the workspace objects to all registered users. See "Export Advanced Options Dialog Box" if you want to export security information such as users, roles, role assignments, and object privileges.

You have two options for exporting metadata. You could either export the entire design or you could export selected objects in the workspace. If you want to export selected objects, then those objects must be within the same navigator. For example, you cannot export a table from the Project Navigator and a public transformation from the Globals Navigator at the same time; you must export them in two separate steps.

Before starting the export operation, take care of the following:

To export metadata from a workspace using the Design Center:

  1. From the Design Center, select the object or objects you want to export.

    You can select multiple objects by holding down the Control key and selecting the objects.

    Note that you may export individual objects such as tables, or groups of objects. When you export projects nodes, or modules, you also export the objects they contain. When you export collections, you also export the objects they reference.

  2. From the File menu, select Export and then Warehouse Builder Metadata.

    Description of exporting_01.gif follows
    Description of the illustration exporting_01.gif

  3. [Optional] If you made changes to the repository metadata prior to running the export utility, a warning dialog box is displayed.

    Click Save to save changes or Revert to revert to the previously saved version.

    Description of exporting_02.gif follows
    Description of the illustration exporting_02.gif

  4. In the Metadata Export Dialog Box:

    • Click Browse to specify the File Name (name and location) of the export file.

    • Click Browse to specify the Log File (name and location).

    • [Optional] Under Annotations, enter comments about the export file.

    • [Optional] Check Export all object dependencies if you are also exporting all the dependencies of the exported objects.

    • [Optional] Click Advanced to export additional metadata. See "Export Advanced Options Dialog Box".

    See "Metadata Export Dialog Box".

  5. Click Export.

  6. When the export completes successfully (see "Metadata Progress Dialog Box"), in the Metadata Export Dialog box, click OK.

Importing Metadata Using the Design Center

You can use the Design Center to import metadata. The Metadata Import Utility also automatically upgrades metadata that was created using an earlier version of Warehouse Builder to the current version. See "Upgrading Metadata from Earlier Releases" for more information about upgrading metadata.

To prepare for importing metadata, you must take care of the following:

Importing Objects

To import objects from an export file using the Design Center:

  1. From the Design Center, select File, select Import, and then select Warehouse Builder Metadata.

    Description of importing_01.gif follows
    Description of the illustration importing_01.gif

  2. [Optional] If you had made changes to the repository metadata prior to running the import utility, a warning dialog box is displayed.

    Click Save to save changes or Revert to revert to the previously saved version.

    Description of importing_02.gif follows
    Description of the illustration importing_02.gif

  3. In the Metadata Import dialog box:

    • Click Browse to specify the File Name (name and location) of the import file.

    • Click Browse to specify the Log File (name and location).

    • Under Object Selection, choose either Import all objects from file or Import selected objects from file.

    • Under Import Option, select one of Create new metadata only, Update metadata replace existing objects and create new metadata, Merge metadata merge existing objects and create new metadata, or Replace existing objects only.

    • Under Match by, select one of Universal Identifier or Names.

    • [Optional] Click Show Summary to view a summary of the contents of the export file. See "File Summary Dialog Box".

    • [Optional] Click Advanced to import metadata for additional languages, security information, or user-defined properties. See "Import Advanced Options Dialog Box".

    See "Metadata Import Dialog Box".

  4. Click Import.

  5. The Metadata Import Progress dialog box is displayed; it indicates the progress of the import. Note that you can cancel an in-progress Metadata Import by clicking Cancel. See "Metadata Progress Dialog Box".

If the MDL file that you selected for import was created using an earlier version of Warehouse Builder, clicking Show Summary, Advanced, or Import displays the Metadata Upgrade dialog box. This dialog box enables you to automatically upgrade the selected MDL file to the current version of Warehouse Builder. For more information about this dialog, see "Metadata Upgrade Dialog Box".

Combining Import Modes and Matching Criteria

Each search method used as matching criteria may be combined with an import mode. Each combination offers different results in the import process. The mode that you select determines how the metadata import utility searches for metadata objects in the workspace, prior to importing.

For example, if the search is by the name of a repository object in the export file, the Metadata Import Utility searches the workspace for the object's name. If an object with the corresponding name is not found, the resulting actions are based on the import mode you select.

Table 12-1 describes what happens in the available import modes for repository objects that either match or do not match the object names.

Table 12-1 Import Mode Results

Import Mode Result Using Matching Names Result Not Using Matching Names

Create Mode

A message is written to the log file that the object exists, and the object is skipped.

A new object is created.

Replace Mode

The object is replaced.

A warning message is written to the log file that the object cannot be replaced because it does not exist in the workspace. The object is skipped.

Update Mode

The object is replaced.

A new object is created.

Merge Mode

The object is merged.

A new object is created.


The MDL reads and processes the imported metadata and writes status and diagnostic information in the log file.

Import Different Base Languages

When you import metadata in multiple languages, the language settings in the target repository may be different from the language settings in the export file. For example, the target repository may have the base language as English and additional language as French and German. But the export file may have the base language as French and additional language as English and German. This section describes how the MDL handles these conditions.

Different Base Languages in the Import File and Target Repository

When you import metadata, MDL compares the ISO identification of the base language in the import file with the ISO identification of the base language of the target repository. The ISO identification consists of the language ID followed by the locale, in the format language_locale. For example, en_US is American English and fr_FR is French.

If the base ISO identification languages are different, MDL displays a warning dialog box informing you that the base languages are different and warns you that Oracle recommends that you import metadata with the same character set and base language. You have the option to continue with the import. Click Yes to continue with the import. Click No to cancel the import.

Note that under certain circumstances, continuing to import metadata when the base languages are different may lead to corruption of the metadata being imported. Oracle recommends that you move metadata between repositories with the same character set and base languages.

If the base ISO identification languages are the same, but the locales are different, the Metadata Import Utility displays a warning dialog box to determine whether you want to continue with the import. For example, the export file contains English and the base language of the repository is American English. Click Yes to import metadata, or click No to cancel the import.

Importing Supported Languages

During the import, MDL checks if the additional languages in the import file exist in the target repository. If the import file contains additional languages that do not exist in the target repository, and you specify that these additional languages are to be imported, the Metadata Import utility writes a warning message in the MDL log file stating that the additional languages are not installed in the repository.

Import Validation Rules

When you import a set of definitions from previously exported metadata, the import utility updates existing definitions within a project. However, certain metadata definitions require attention to ensure that they are updated correctly. The following are examples of some of the errors you may see:

  • Mapping Definitions. The Metadata Import Utility binds imported mapping operators to their physical objects if the associated objects exist in the workspace. However, if the associated physical objects do not exist in the workspace, the imported mapping operators are not bound. The Metadata Import Utility writes a warning message in the log file, which states that the mapping operators are not bound. You must then synchronize the new mapping operators with the physical objects they represent.

  • Foreign Key Definitions. It is possible that a source MDL file contains foreign key references to unique or primary keys that are not in the target workspace. If the referenced unique or primary keys for any foreign key appearing in the MDL file do not exist in the target workspace, the MDL Import Utility writes a warning message in the log file, which states that the workspace does not contain a referenced key for the foreign key.

Upgrading Metadata from Earlier Releases

While importing metadata, the Metadata Import Utility automatically upgrades metadata created using earlier releases to Oracle Warehouse Builder 11g Release 2 (11.2). You do not have to manually upgrade the metadata from a previous release of Warehouse Builder.

When you import an MDL file, the version used to create the file is automatically detected. If the MDL file was created using an earlier release of Oracle Warehouse Builder, the Metadata Upgrade dialog box is displayed. This dialog box enables you to upgrade the MDL file to the current version. See "Metadata Upgrade Dialog Box".

If you import an .mdl file that contains metadata for gateway modules (such as DB2 or Informix) from an older version of Warehouse Builder, the file may not import the metadata into the corresponding source module folders of a project. These imported files are stored under the Others node in the Project Navigator. You must manually copy the metadata for the gateway modules into the correct source module folders.

The production versions of Warehouse Builder from which metadata is automatically upgraded to Oracle Warehouse Builder 11g Release 2 (11.2) are as follows:

If you must upgrade an MDL file from an older version of OWB, you must first upgrade it to one of OWB 9.2, 10.1, 10.2, or 11.1, and then upgrade this intermediate MDL file to OWB 11.2.

Changes to Workspace Objects When Upgrading from OWB 9.2

When you upgrade from OWB 9.2, the upgrade utility makes the following changes to objects in the workspace:

  • Dimension and Cube Mapping Operators: The mapping operators for dimensions and cubes are converted to table operators. These table operators use the physical tables created by the MDL Upgrade Utility for dimensions and cubes.

  • Dimensions: An associated dimension table is created with the same name as the dimension. The table contains the columns, constraints, and attribute sets defined in the Dimension Editor Table Properties of the dimension in the previous release.

  • Mapping Display Sets for Dimension Hierarchies: Any mapping sets originally created based on the named attribute set for a dimension hierarchy are removed. This is because display sets for dimension hierarchies are no longer automatically created and maintained.

  • Dimension Attributes: For each level attribute upgraded, a dimension attribute with the same name is created, if it does not exist in the dimension.

  • Cubes: An associated cube table is created with the same name as the cube. The cube table contains columns, constraints, and attribute sets defined in the Cube Editor Table Properties of the cube in the previous release.

  • Intelligence Objects and Reports: In the previous release, intelligence objects and reports were available only using OMB Plus scripting. These objects are not upgraded.

  • Locations and Control Center Connections: Locations and Control Center connections are moved out of the projects that own them so that they can be shared across the entire workspace. Thus the statistics in the import log file displays an additional project for these objects.

  • Control Centers and Locations: After an upgrade, there is no association between the locations and the control centers that they reference. You must review the control center details using the Edit Control Center dialog box and select the locations associated with this control center.

  • Advanced Queues: An associated queue table is created based on the property AQ queue table name. The queue table created by the MDL File Upgrade Utility contains a column whose data type is the object type for that advanced queue.

  • Advanced Queue Operator in a Mapping: Mapping Advanced Queue operators are changed to contain only one attribute called PAYLOAD. For Mapping Advanced Queue operators that are used as a source, a new Expand operator is added after the Mapping Advanced Queue operator. For Mapping Advanced Queue operators that are used as a target, a new Construct operator is added before the Mapping Advanced Queue operator.

  • Mapping Operator Names: The MDL Upgrade Utility ensures that the physical names and business names of all mapping operators are unique.

Changes to Workspace Objects When Upgrading from OWB 10.1, 10.2 or 11.1

When you upgrade from OWB 10.1, 10.2, or 11.1 to OWB 11.2, the upgrade utility makes the following changes to objects in the workspace:

  • Mapping Table Function Operators: The mapping operators for table functions are upgraded to have only one input group and one output group. Old input groups that were configured as a REF cursor type are upgraded to a SYS_REFCURSOR type, and a new construct operator is added to the map; its input group values are the same as in the REF cursor type input group, and the output group attribute is set to SYS_RECURSOR type.

  • Mapping Key Lookup Operators: The mapping operators for key lookups are upgraded to the new lookup operator.

  • Stream Capture Process Objects: Stream capture process objects are not upgraded.

  • Business Presentation Modules: Business presentation modules and their contents are not upgraded.

  • BI Beans Locations: BI beans locations are not upgraded.

Checking for Warnings and Error Messages

After upgrading the metadata, check the log file for warnings and errors.

  • If you receive warnings during the upgrade, the upgrade utility completes and logs the warnings. If you receive errors, the upgrade utility terminates and logs the errors.

  • If warnings and errors are shown after an upgrade, search for the words Warning and Error in the log file to determine the problem.

  • If an unexpected error occurs and the upgrade terminates, the log file contains the details. Check your log file or contact Oracle Support.

Design Center Metadata Management Dialog Boxes

The Design Center uses several dialogs to manage metadata export, import, and upgrade. These are:

Metadata Export Dialog Box

The Metadata Export dialog box displays the names and the types of the exported objects.

Description of exporting_03.gif follows
Description of the illustration exporting_03.gif

The Metadata Export dialog box also contains the following items:

  • Annotations: Use this field to enter any comments about the file that contains the exported objects.

  • File Name: Displays a default path and file name for the export file. You can retain this default or specify a directory and file name. Type the name of the export file to create or click Browse to locate a directory or file. The file name extension commonly used is .mdl.

  • Log File: Use this field to specify the file name and path for the log file that stores diagnostic and statistical information about the export. See "Metadata Loader Log File"

  • Export all object dependencies: Select this option to export all the dependencies of the objects being exported. For example, when you export a table, the location to which the table is deployed is also exported.

    Note that public objects such as locations, public transformations, public experts, public icon sets, or public data rules belong to a project called PUBLIC_PROJECT. You can export the PUBLIC_PROJECT and its objects if the selected exported objects have a dependency on the public objects and if you select the Export all object dependencies option.

  • Advanced: Use the Advanced button to export additional metadata such as user-defined properties, security information, and additional languages. See "Export Advanced Options Dialog Box".

Click Export to export the metadata for the selected objects. The Metadata Export Progress dialog box is displayed. See "Metadata Export Dialog Box" for more information about the contents of this dialog box.

Export Advanced Options Dialog Box

Use the Export Advanced Options dialog box to export any of the following:

  • Additional language metadata

  • User-defined definitions

  • Security information

Description of exporting_04.gif follows
Description of the illustration exporting_04.gif

This dialog box contains two sections: Languages and Administration.

Languages

The Base Language field displays the base language of the repository. Warehouse Builder exports and imports data in the base language.

You can specify additional languages to export and import objects that contain translations for their business names and descriptions. The Available Languages list displays the list of languages that are installed in the repository. To export or import additional languages, select the language and click the arrows to move the language from the Available Languages list to the Selected Languages list. You may choose multiple languages at the same time by holding down the Control or Shift key while making your selection.

Note that the Available Languages list contains language entries only if you installed additional languages in the repository. For example, the repository has American English as base language, and additional languages French and Simplified Chinese. While exporting metadata from the repository, you may select French as the additional language. The Metadata Export Utility then exports the base language of the object, American English, and the additional language French for objects that contain a French translation. Note that additional languages are exported for an object only if they contain translations for the business names and descriptions.

Administration

You may export additional metadata if you have administrator privileges. The options you may choose to export additional metadata are as follows:

  • Export user-defined definition: Select this option to export the definitions of user-defined objects and user-defined properties.

  • Export security information: Select this option to include security information such as object privileges or role assignments made to users. See Chapter 13, "Managing Security" for more information about security.

After you specify the options on the Export Advanced Options dialog box, click OK to close this dialog box and return to the Metadata Export dialog box.

Metadata Import Dialog Box

Use the Metadata Import dialog box to specify the information required to import metadata in an export file.

Description of importing_03.gif follows
Description of the illustration importing_03.gif

Specify the following information on this dialog box:

  • File Name: Type the name of the MDL file or click Browse to locate the MDL file you want to import.

  • Log File: Type the name of the log file, along with the path, that will store diagnostic and statistical information about the import. You can also click Browse to locate the log file. See "Metadata Loader Log File" for more information about log files.

  • Object Selection: The Metadata Import Utility enables you to select the objects that you want to import from the MDL file. The Object Selection section contains the following options:

    • Import all objects from file: Select this option to import all objects contained in the export file.

    • Import selected objects from file: Select this option to import only some of the objects contained in the MDL file. Click Select Objects to select the objects that you want to import. The Import Object Selection dialog box is displayed.

      The Import Object Selection dialog box is displayed contains two sections: Available and Selected. The Available section contains primary objects such as projects, modules, tables, views, and connections, which are specified in the MDL file. Expand the nodes in this section to view the objects they contain. When you select a node, all the objects that it contains are included in the import. For example, if you select a module node, all the objects contained in the module are imported. Use the shuttle buttons to move the selected objects from the Available section to the Selected section.

      The MDL file that is imported may also contain administrative objects. To import these administrative objects, you must have administrative privileges. If these privileges are absent, the following occurs:

      • The Available section of the Import Object Selection Page dialog box does not display any administrative objects that the MDL file may contain.

      • The Import Utility displays an alert that the user does not have the required administrative privileges to perform the import, provided the MDL file contains only administrative objects.

  • Import Option: Use the Import Option section to select the import mode. You can select one of the following options for the import mode:

    • Create new metadata only: This option, known as create mode, adds new objects to a workspace.

    • Update metadata (replace existing objects and create new metadata): This option, known as update mode, adds new objects to a workspace and also replaces existing objects with those in the MDL file that is imported.

    • Merge metadata (merge existing objects and create new metadata): When you select this option, known as merge mode, the MDL adds new objects and overwrites existing objects in the workspace only if they differ from those in the MDL file. The merge mode does not delete existing objects. Note that you cannot import metadata using the merge mode for mappings, pluggable mappings, and data auditors.

    • Replace existing objects only: This option, known as replace mode, replaces existing objects in your workspace but does not add new objects. In this mode, the Metadata Import Utility overwrites any existing metadata.

    When you import metadata using the update or the replace modes, the import completely replaces the child objects of existing objects, so that the final object is exactly the same as the source object. Any existing children of a repository object that are not replaced or added are deleted. This occurs regardless of whether a child object occurs in a mapping or is a foreign, primary, or unique key column in a table or view.

    For example, in the MDL export file, the CUST table contains three columns with the physical names: last_name, first_name, and middle_init. In the workspace, the same table exists, and contains four columns with the physical names: last_name, first_name, status, and license_ID. During a replace operation, the columns last_name and first_name are replaced, column middle_init is added, and column status and license_ID are deleted. The final result is that the CUST table in the workspace contains the same metadata from the CUST table in the export file.

    Note that using the replace and update modes may cause loss of data constraints, metadata physical property settings, data loading properties, and mapping attribute connections. If you choose to use replace or update modes, ensure that you have the option of restoring the workspace from a backup.

  • Match By: When you use the metadata import utility, it first searches the workspace for metadata objects that exist in the workspace and compares them to those in the import file. To compare metadata in the import file with the existing workspace metadata, it uses the matching criteria. How the comparison is made is determined by the import mode and by the chosen search method.

    The Match By section provides the following options for matching criteria. By default, the import utility searches by UOIDs. Note that MDL import does not support merging existing mappings.

    • Universal Identifier option searches the workspace using the Universal Object Identifiers (UOIDs) of the objects that are imported. The Metadata Import Utility uses the UOIDs to determine whether an object must be created, replaced, or merged during the import operation. Use this method if you want to maintain UOIDs across different workspaces even when object names in the target workspace have changed.

    • Names option searches the workspace using the names of the objects that are imported. Physical names are exported to the export file; the physical name determines whether an object must be created, replaced, or merged during an import operation. Use this method if you want to create new UOIDs for those objects when object names in the target schema change.

Import Advanced Options Dialog Box

Use the Import Advanced Options dialog box to import any of the following:

  • Additional language metadata

  • User-defined definitions

  • Security information

Description of importing_04.gif follows
Description of the illustration importing_04.gif

This dialog box contains two sections: Languages and Administration.

Languages

The Base Language displays the base language of the repository. By default, data is imported in the base language.

You can specify additional languages to import. The Metadata Import Utility imports the translations of the object for business name and description. The Available Languages list displays the list of languages that are specified in the MDL file. For example, the MDL file contains the additional languages French and Simplified Chinese, but your repository contains only French as the additional language. Then the Available Languages list displays only French. Select the language you want to import and click the arrow to move the language to the Selected Languages list. See "Import Different Base Languages".

Administration

This option is available only if you have administrator privileges and the metadata exists in the MDL file used for import. The options you may choose to import additional metadata are as follows:

  • User-defined definitions: To import the definitions for the user-defined objects and the user-defined properties, select the Import User-defined definitions option.

  • Security Grants: Select Import security information to import security information such as object privileges and role assignments made to users.

If the MDL file contains any of these objects, then you can import this additional metadata.

When you import an MDL file into a new workspace, if you want to inherit the security information from the old workspace, you must import the security information before you import other objects. To do this you need to be connected to the workspace as a user with administrator privileges.

After you make your selections on the Import Advanced Options dialog box, click OK to save your selections and return to the Metadata Import dialog box.

Name Conflicts

Name conflicts may occur in one of the following cases:

  • A different object with the same name exists in the target workspace.

  • A different object with the same business name exists in the target workspace.

  • A different object with the same UOID exists in the workspace.

When a name conflict occurs, the MDL reports an error and terminates the import.

File Summary Dialog Box

The File Summary dialog box contains a brief summary of the contents of the export file. The information on this page is divided into the following sections:

  • File section contains the name of the data file, the creation timestamp, the name of the export user, the workspace connection information, the version of the Design Center used for the export, and annotations.

  • Administration section contains information about the users and roles. It also lists the following details:

    • Base language of the export file

    • Additional languages in the export file

    • Whether security information were included in the export file

    • Whether user-defined definitions were included in the export file

  • Statistics section contains details about the types of objects contained in the export file and the number of objects of each type.

Metadata Upgrade Dialog Box

This dialog box is displayed automatically when it is determined that the MDL file being imported was created using a previous version. Use the File Name field to specify the name of the file that stores the upgraded MDL file. You can also click Browse to locate a directory or MDL file.

Click Upgrade to upgrade the MDL file to the current version. After the Upgrade completes, the Metadata Upgrade dialog box is closed. Click Cancel if you do not want to upgrade the MDL file.

Metadata Progress Dialog Box

The Metadata Progress dialog box is titled either Metadata Export Progress, Metadata Import Progress, or Metadata Upgrade Progress. It displays a progress bar that indicates the relative completeness (as a percentage) of the metadata export, import, or upgrade activity. If the operation is successful, a message indicating this displays above the progress bar; it may also display that an error occurred.

Description of exporting_05.gif follows
Description of the illustration exporting_05.gif

To view detailed information about the metadata export or import, click Show Details. The message log is displayed. The message log contains the following information:

  • Start time of the export or import

  • Names and types of objects exported or imported

  • Warning or error messages

  • End time of the export or import

  • Location of the export or import log file

  • Total export or import time in hh:mi:ss or milliseconds

You can hide the message log by clicking Hide Details.

To view details about the exported or imported objects, click Show Statistics. The Metadata Results dialog is displayed. See "About Metadata Loader Results".

Note that you can cancel an in-progress Metadata Export or Import by clicking Cancel.

Once the export or import completes, click OK in the Metadata Progress dialog.

Metadata Loader Utilities

The Metadata Loader consists of the following two utilities:

MDL uses its own format, and the Metadata Import Utility only reads files of MDL format (files created by the Metadata Export utility). The Metadata Loader file is a formatted ZIP file.

Metadata Export Utility

The Metadata Export Utility extracts metadata objects from a workspace and writes the information into a ZIP format file. This ZIP file has an .mdl extension and contains the following files:

  • Metadata Loader XML file: This file contains the objects extracted from the workspace and formatted in XML. It has the same name as the name of the ZIP file, but with the extension .mdx.

  • Catalog: The catalog file is called mdlcatalog.xml and it contains internal information about the Metadata Loader XML file.

The Metadata Export Utility enables you to specify a file name and a path for the exported MDL file. For example, you export the repository metadata into a file called sales.mdl. When you unzip this MDL ZIP file, you obtain two files. The file sales.mdx contains the repository objects. The file mdlcatalog.xml contains internal information about the MDL XML file.

You can export an entire project, collections, public objects, locations, or any subset of objects. If you export a subset of objects, the MDL exports definitions for each object that you have selected and the parent objects to which the subset belongs. This enables the MDL to maintain the tree relationships for those objects during metadata import.

For example, if you export a single dimension, the export file contains definitions for the dimension, the module to which the dimension belongs, the project to which the module belongs, and the configurations for the dimension.

If you are exporting a subset of objects, ensure that you both export and import all referenced object. You may export the objects referenced by a set of objects by selecting the Export All Dependencies option on the Metadata Export dialog box. For example, if you export a table EMPLOYEES and it contains a foreign key reference to the table DEPARTMENTS, you may choose to export both tables.

Metadata Import Utility

The Metadata Import Utility reads the metadata information from an exported MDL file and creates, replaces, or merges the metadata objects into a workspace. It imports information that belongs to exported metadata objects, such as table columns and their constraints, data loading configuration parameters, and named attribute sets. The Metadata Import Utility enables you to import repository objects even if the references for those objects cannot be satisfied.

You can use the Metadata Import Utility to import objects into a project or a collection. The Metadata Import Utility only reads files created by the metadata export utility.

If the MDL file being imported was created using an earlier product version, the Metadata Import Utility automatically upgrades it to the current version.

See Also:

"Upgrading Metadata from Earlier Releases" for more information about the automatic upgrade of MDL files

Multiple Session Concurrency and MDL

The repository allows multiple clients to access the same workspace concurrently. Warehouse Builder uses locks to allow only one client to change repository objects. While an object is locked, other clients can only view it in the state it existed after the last transaction instigated by any user is committed.

When replacing or merging objects, the MDL acquires locks on the primary objects that exist both in the repository and in the MDL file. Primary objects include, but are not limited to, projects, modules, tables, dimensions, cubes, mappings, views, and flat files. Secondary objects, such as columns and mapping attributes, are not locked. If locks cannot be obtained because other users are locking the primary objects, then the import fails. Therefore, you must be able to hold locks for primary objects that you are importing. To ensure a successful metadata import, you may need to be the sole client accessing the workspace.

The MDL saves changes made to the workspace after a successful metadata import (any import with no error messages, including imports with only information or warning messages). The MDL also executes a rollback after an unsuccessful import.

Metadata Loader Log File

Whenever you export or import repository metadata, the MDL writes diagnostic and statistical information to a log file. You can specify the location of the log file when you call the MDL.

The log file enables you to monitor and troubleshoot export and import activities in detail and contains the following information:

About Metadata Loader Results

When you use the Metadata Loader Export or Import utilities, you can view the results of a successful export or import task. Use the Metadata Export Results dialog box or the Metadata Import Results dialog box to ensure that all of the objects were exported or imported. To view the results dialog box, click Show Details on the Metadata Export Progress dialog box or the Metadata Import Progress dialog box. This displays the Message Log. Click Show Statistics at the end of this log.

The results dialog box contains the following information:

Managing Versions and History with the Metadata Loader

Using the Metadata Loader (MDL) utility, you can import and export metadata from any object in the Projects Navigator, Globals Navigator, and Connection Navigator. You can then move exported files into a third-party version control tool such as Oracle Repository, ClearCase, or SourceSafe. You can enter annotations for your MDL export file to keep track of the information contained in the file.

The Metadata Loader (MDL) enables you to populate a new repository and transfer, update, or restore a backup of existing repository metadata. You can copy or move metadata objects between repositories, even if those repositories reside on platforms with different operating systems.

Accessing the Metadata Loader

You can access the Metadata Loader using either the graphical user interface described in this section or using the OMB Plus scripting language described in Oracle Warehouse Builder API and Scripting Reference.

While the graphical interface guides you through the most commonly performed export and import tasks, the OMB Plus scripting language enables you to perform more specialized export and import tasks and enables you to manage a control file.

About Metadata Loader Control Files

When you use the OMB Plus commands related to the Metadata Loader, a control file provides you with greater control over how objects are imported or exported. For example, by default, the Metadata Loader exports objects into a binary zip format. To override the default of exporting to a zip file, use OMBEXPORT MDL_FILE with the CONTROL_FILE option with a control file that contains the option ZIPFILEFORMAT=N.

See Oracle Warehouse Builder API and Scripting Reference for more information about using a control file, the Metadata Loader, and information about each of the following commands:

  • OMBIMPORT

  • OMBEXPORT

  • OMUIMPORT

  • OMUIMPORT MDL_FILE

  • OMBIMPORT MDL_FILE

  • OMUEXPORT MDL_FILE

  • OMBEXPORT MDL_FILE