Saturday, 20 October 2012

Informatica Constraint Based Loading

Constraint based loading is used when we need to populate the tables, which have parent child relationship, in the same mapping. This option loads record first in the parent table before loading the corresponding child records in the child tables.

Constrained base load order Informatica load the data on the basis of constraints to target tables, basically Primary key and Foreign key

When target tables have no key relationships, the Informatica Server does not perform constraint-based loading. Similarly, when target tables have circular key relationships, the Informatica Server reverts to a normal load. For example, you have one target containing a primary key and a foreign key related to the primary key in a second target. The second target also contains a foreign key that references the primary key in the first target. The Informatica Server cannot enforce constraint-based loading for these tables. It reverts to a normal load. 

Steps for creating mapping following Constraint based loading
  • First import the source and target tables (Take for example Product and Customer table)
  • Make sure that the foreign key relationship exists between the Product and Customer table else create the relationship in the target analyzer
  • Create the mapping with the source pointing to both the target Product and Customer table.
  • Once mapping is done create workflow and session and check the option of constraint based load ordering.
  • Save the mapping and run the workflow

No comments:

Post a Comment

Related Posts Plugin for WordPress, Blogger...