Validating a Mapping - Informatica

When you develop a mapping, you must configure it so the Integration Service can read and process the entire mapping. The Designer marks a mapping invalid when it detects errors that will prevent the Integration Service from running sessions associated with the mapping.

The Designer marks a mapping valid for the following reasons:

  • Connection validation. Required ports are connected and that all connections are valid.
  • Expression validation. All expressions are valid.
  • Object validation. The independent object definition matches the instance in the mapping.
  • Data flow validation. The data must be able to flow from the sources to the targets without hanging at blocking transformations.

Connection Validation

The Designer performs connection validation each time you connect ports in a mapping and each time you validate or save a mapping. When you connect ports, the Designer verifies that you make valid connections. When you save or validate a mapping, the Designer verifies that the connections are valid and that all required ports are connected. When you save or validate a mapping, the Designer makes the following connection validations:

  • At least one source and one target must be connected.
  • Source qualifiers must be mapped to a target.
  • Mapplets must be connected. At least one mapplet input port and output port is connected to the mapping. If the mapplet includes a source qualifier that uses an SQL override, the Designer prompts you to connect all mapplet output ports to the mapping.
  • Datatypes between ports must be compatible. If you change a port datatype to one that is incompatible with the port it is connected to, the Designer generates an error and invalidates the mapping. For example, you have two Date/Time ports connected, and you change one port to a Decimal. The Designer invalidates the mapping. You can however, change the datatype if it remains compatible with the connected ports, such as Char and Varchar.

Expression Validation

You can validate an expression in a transformation while you are developing a mapping. If you did not correct the errors, the Designer writes the error messages in the Output window when you save or validate the mapping.

If you delete input ports used in an expression, the Designer marks the mapping as invalid.

Object Validation

When you validate or save a mapping, the Designer verifies that the definitions of the independent objects, such as sources or mapplets, match the instance in the mapping. If any object changes while you configure the mapping, the mapping might contain errors.

If any object changes while you are not configuring the mapping, the Designer and other PowerCenter Client applications track the effects of these changes on the mappings. The Repository Manager displays the status of mappings, so you can see if a mapping is valid or not. If you notice that a mapping is invalid, you can open the mapping and validate it to see the error messages in the Output window.

Data Flow Validation

When you validate or save a mapping, the Designer verifies that the data can flow from all sources in a target load order group to the targets without the Integration Service blocking all sources.

Mapings that include blocking transformations might hang at runtime with any of the following mapping configurations:

  • You connect one source pipeline to multiple input groups of the blocking transformation.
  • You connect the sources and transformations in a target load order group in such a way that multiple blocking transformations could possibly block all source pipelines. Depending on the source data used in a session, a blocking transformation might block data from one source while it waits for a row from a different source.

When you save or validate a mapping with one of these configurations, the Designer marks the mapping invalid.
When the Designer marks a mapping invalid because the mapping violates data flow validation, you must configure the mapping differently, or use a non-blocking transformation where possible.

The following figure shows mappings that are invalid because one source provides data for multiple input groups of a blocking transformation:

Data Flow Validation

To make the mappings valid, use a non-blocking transformation for MGT1 or create two instances of the same source and connect them to the blocking transformation.

The following figure shows two similar mappings, one which is valid, one which is invalid:

Data Flow Validation

Mapping A contains two multigroup transformations that block data, MGT1 and MGT2. If you could run this session, MGT1 might block data from S1 while waiting for a row from S2. And MGT2 might block data from S2 while waiting for a row from S1. The blocking transformations would block both source pipelines and the session would hang. Therefore, the Designer marks the mapping invalid.

Mapping B contains one multigroup transformation that blocks data, MGT1. Blocking transformations can never block all input groups, so MGT1 might block either S1 or S2, but never both. MGT2 is not a blocking transformation, so it will never block data. Therefore, this session will not hang at runtime due to blocking. The Designer marks the mapping valid.

Steps to Validate a Mapping

You can validate a mapping while you are working on it through the Designer. Also, when you click Repository > Save, the Designer validates all mappings since the last time you saved. When you validate or save a mapping the results of the validation appear in the Output window. The Repository Manager also displays whether a mapping is valid.

To validate a mapping, check out and open the mapping, and click Mappings > Validate.

If the Output window is not open, click View > Output Window. Review any errors to determine how to fix the mapping.

Validating Multiple Mappings

You can validate multiple mappings without fetching them into the workspace. To validate multiple mappings you must select and validate the mappings from either a query results view or a view object dependencies list.

Note:If you use the Repository Manager, you can select and validate multiple mappings from the Navigator.

You can save and optionally check in mappings that change from invalid to valid status as a result of the validation.

To validate multiple mappings:

  1. Select mappings from either a query or a view dependencies list.
  2. Right-click one of the selected mappings and choose Validate.
  3. The Validate Objects dialog box displays.
  4. Choose whether to save objects and check in objects that you validate.

All rights reserved © 2018 Wisdom IT Services India Pvt. Ltd DMCA.com Protection Status

Informatica Topics