Command Reference > Working with pmrep Files > Using the Object Import Control File
  

Using the Object Import Control File

When you use the pmrep ObjectImport command, you can supply a control file to answer questions that you normally address when you import objects with the Import Wizard. To create a control file, you must create an XML file defined by impcntl.dtd. The import control file is installed with the PowerCenter Client, and you must include its location in the input XML file.
The following is a sample of the impcntl.dtd file:
<!-- Informatica Object Import Control DTD Grammar - >

<!--IMPORTPARAMS This inputs the options and inputs required for import operation -->
<!--CHECKIN_AFTER_IMPORT Check in objects on successful import operation -->
<!--CHECKIN_COMMENTS Check in comments -->
<!--APPLY_LABEL_NAME Apply the given label name on imported objects -->
<!--RETAIN_GENERATED_VALUE Retain existing sequence generator, normalizer and XML DSQ current values in the destination -->
<!--COPY_SAP_PROGRAM Copy SAP program information into the target repository -->
<!--APPLY_DEFAULT_CONNECTION Apply the default connection when a connection used by a session does not exist in the target repository -->
<!ELEMENT IMPORTPARAMS (FOLDERMAP*, TYPEFILTER*, RESOLVECONFLICT?)>
<!ATTLIST IMPORTPARAMS
CHECKIN_AFTER_IMPORT (YES | NO) "NO"
CHECKIN_COMMENTS CDATA #IMPLIED
APPLY_LABEL_NAME CDATA #IMPLIED
RETAIN_GENERATED_VALUE (YES | NO) "NO"
COPY_SAP_PROGRAM (YES | NO) "YES"
APPLY_DEFAULT_CONNECTION (YES | NO) "NO"
>

<!--FOLDERMAP matches the folders in the imported file with the folders in the target repository -->
<!ELEMENT FOLDERMAP EMPTY>
<!ATTLIST FOLDERMAP
SOURCEFOLDERNAME CDATA #REQUIRED
       SOURCEREPOSITORYNAME CDATA #REQUIRED
TARGETFOLDERNAME CDATA #REQUIRED
TARGETREPOSITORYNAME CDATA #REQUIRED
>

<!--Import will only import the objects in the selected types in TYPEFILTER node -->
<!--TYPENAME type name to import. This should comforming to the element name in powermart.dtd, e.g. SOURCE, TARGET and etc.-->
<!ELEMENT TYPEFILTER EMPTY>
<!ATTLIST TYPEFILTER
TYPENAME CDATA #REQUIRED
>

<!--RESOLVECONFLICT allows to specify resolution for conflicting objects during import. The combination of specified child nodes can be supplied -->
<!ELEMENT RESOLVECONFLICT (LABELOBJECT | QUERYOBJECT | TYPEOBJECT | SPECIFICOBJECT)*>

<!--LABELOBJECT allows objects in the target with label name to apply replace/reuse upon conflict -->
<!ELEMENT LABELOBJECT EMPTY>
<!ATTLIST LABELOBJECT
LABELNAME         CDATA                       #REQUIRED
RESOLUTION       (REPLACE | REUSE | RENAME) #REQUIRED
>

<!--QUERYOBJECT allows objects result from a query to apply replace/reuse upon conflict -->
<!ELEMENT QUERYOBJECT EMPTY>
<!ATTLIST QUERYOBJECT
QUERYNAME          CDATA                         #REQUIRED
        RESOLUTION         (REPLACE | REUSE | RENAME) #REQUIRED
>

<!--TYPEOBJECT allows objects of certain type to apply replace/reuse upon conflict-->
<!ELEMENT TYPEOBJECT EMPTY>
<!ATTLIST TYPEOBJECT
OBJECTTYPENAME            CDATA                      #REQUIRED
RESOLUTION                REPLACE | REUSE | RENAME) #REQUIRED
>

<!--SPECIFICOBJECT allows a particular object(name, typename etc.) to apply replace/reuse upon conflict -->
<!--NAME Object name-->
<!--EXTRANAME Source DBD name - required for source object to identify uniquely-->
<!--OBJECTTYPENAME Object type name-->
<!--FOLDERNAME Folder which the object belongs to-->
<!--REPOSITORYNAME Repository name that this object belongs to-->
<!--RESOLUTION Resolution to apply for the object in case of conflict-->
<!ELEMENT SPECIFICOBJECT EMPTY>
<!ATTLIST SPECIFICOBJECT
NAME CDATA #REQUIRED
DBDNAME CDATA #IMPLIED
OBJECTTYPENAME CDATA #REQUIRED
FOLDERNAME CDATA #REQUIRED
REPOSITORYNAME CDATA #REQUIRED
RESOLUTION (REPLACE | REUSE | RENAME) #REQUIRED>

Object Import Control File Parameters

The following table lists pmrep Object Import control file parameters:
Element
Attribute Name
Attribute Description
IMPORTPARAMS
CHECKIN_AFTER_IMPORT
Required if versioning is enabled.Checks in objects when they successfully import.
IMPORTPARAMS
CHECKIN_COMMENTS
Optional. Applies the comments to the checked in objects.
IMPORTPARAMS
APPLY_LABEL_NAME
Optional. Applies the label name on the imported objects.
IMPORTPARAMS
RETAIN_GENERATED_VALUE
Required if you use Sequence Generator, Normalizer, or XML Source Qualifier transformations. Retains existing Sequence Generator, Normalizer, and XML Source Qualifier transformation current values in the destination.
IMPORTPARAMS
COPY_SAP_PROGRAM
Optional. Copies SAP program information into the target repository.
IMPORTPARAMS
APPLY_DEFAULT_CONNECTION
Optional. Applies the default connection when a connection used by a session does not exist in the target repository. The default connection is the first connection from the sorted list of available connections. Finds the list of connections in the Workflow Manager.
FOLDERMAP
SOURCEFOLDERNAME
Required. Import folder name to match to a folder in the target repository.
FOLDERMAP
SOURCEREPOSITORYNAME
Required. Repository containing the source folder.
FOLDERMAP
TARGETFOLDERNAME
Required. Target folder name for matching.
FOLDERMAP
TARGETREPOSITORYNAME
Required. Repository containing the target folder.
TYPEFILTER
TYPENAME
Optional. Imports the objects from a specific node, such as sources, targets, or mappings.
RESOLVECONFLICT
LABELOBJECT, QUERYOBJECT, TYPEOBJECT, AND SPECIFICOBJECT elements.
You can specify conflict resolutions for objects.
LABELOBJECT
LABELNAME
Required. Identifies objects by label name for conflict resolution specification.
LABELOBJECT
RESOLUTION
Required. Replace, Reuse, Rename.
QUERYOBJECT
QUERYNAME
Required. Identifies objects from this query for conflict resolution specification.
QUERYOBJECT
RESOLUTION
Required. Replace, Reuse, or Rename.
TYPEOBJECT
OBJECTTYPENAME
Required. Object type for this conflict resolution. For a list of object types, see Object Import Control File Parameters.
TYPEOBJECT
RESOLUTION
Required. Replace, Reuse, or Rename.
SPECIFICOBJECT
NAME
Required. Specific object name for this conflict resolution.
SPECIFICOBJECT
DBDNAME
Optional. Source DBD to identify source object.
SPECIFICOBJECT
OBJECTTYPENAME
Required. Object type for this conflict resolution. For a list of object types, see Object Import Control File Parameters.
SPECIFICOBJECT
FOLDERNAME
Required. Source folder the containing object.
SPECIFICOBJECT
REPOSITORYNAME
Required. Source repository containing the object.
SPECIFICOBJECT
RESOLUTION
Required. Replace, Reuse, or Rename.
You can use the following object types with the OBJECTTYPENAME attribute: