Propagating Port Attributes - Informatica

When you edit a port name in a transformation, by default, the Designer propagates references to that port in the expressions, conditions, and other ports in that transformation. You can also propagate changed attributes throughout the mapping.

The Designer propagates ports, expressions, and conditions based on the following factors:

  • The direction that you propagate. You can propagate changes forward, backward, or in both directions.
  • The attributes you choose to propagate. You can propagate port name, datatype, precision, scale, and description.
  • The type of dependencies. You can propagate changes to dependencies along a link path or to implicit dependencies within a transformation.

Understanding Dependency Types

When you propagate port attributes, the Designer can update the following dependencies:

  • Link path dependencies. A link path dependency is a dependency between a propagated port and the ports in its link path. When you propagate link path dependencies, the Designer also performs default updates to references in expressions and conditions that depend on ports in the link path.
  • Implicit dependencies. An implicit dependency is a dependency within a transformation between two ports based on an expression or condition.
  • For example, when you change the datatype of a port that is used in a lookup condition, the Designer propagates the datatype change to the other port dependent on the condition.

Propagating Dependencies in a Link Path

When you propagate dependencies in a link path, the Designer updates all the input and input/output ports in its forward link path and all the output and input/output ports in its backward link path. The Designer performs the following updates:

  • Updates the port name, datatype, precision, scale, and description for all ports in the link path of the propagated port.
  • Updates all expressions or conditions that reference the propagated port with the changed port name.
  • Updates the associated port property in a dynamic Lookup transformation if the associated port name changes.
  • Updates the port name of Custom transformation port dependencies.

Note:When you propagate a port name, the Designer appends “1” to the port name if a port with the same name exists in the transformation.

Example

In the following mapping, the QTY port in the Joiner transformation links to the QTY port in the Aggregator transformation. The Aggregator transformation references the QTY port in the expressions for TOTAL_QUANTITY and TOTAL_REVENUE:

Propagating Dependencies in a Link Path

You make the following changes to the QTY port in the Joiner transformation:

  • You change the port name QTY to QUANTITY.
  • You change the datatype from Decimal to Integer.

When you propagate forward the attributes, the Designer updates the following dependencies in the Aggregator transformation:

  • The Designer updates QTY port name to QUANTITY.
  • The Designer updates the reference to QTY port name in the expressions for the TOTAL_QUANTITY and TOTAL_REVENUE ports change to QUANTITY.
  • The Designer updates the datatype of QTY port name to Integer.

Propagating Implicit Dependencies

You can propagate datatype, precision, scale, and description to ports with implicit dependencies. When you click Options in the Propagate Ports dialog box, you can choose to parse conditions and expressions to identify the implicit dependencies of the propagated port. All ports with implicit dependencies are output or input/output ports.

When you include conditions the Designer updates the following dependencies:

  • Link path dependencies
  • Output ports used in the same lookup condition as the propagated port
  • Associated ports in dynamic Lookup transformations that are associated with the propagated port
  • Output ports used by a Custom transformation to define a port relationship with one or more input or input/ output ports
  • Master ports used in the same join condition as the detail port

When you include expressions, the Designer updates the following dependencies:

  • Link path dependencies
  • Output ports containing an expression that uses the propagated port

The Designer does not propagate to implicit dependencies within the same transformation. You must propagate the changed attributes from another transformation. For example, when you change the datatype of a port that is used in a lookup condition and propagate that change from the Lookup transformation, the Designer does not propagate the change to the other port dependent on the condition in the same Lookup transformation.

Example

You have the following mapping:

Propagating Implicit Dependencies

The MANUFACTURER_ID port in the Aggregator transformation links to the IN_MANUFACTURER_ID port in the Lookup transformation. The Lookup transformation uses the following lookup condition:

MANUFACTURER_ID = IN_MANUFACTURER_ID

You change the datatype of the MANUFACTURER_ID port from integer to decimal in the Aggregator transformation. You choose to parse conditions to infer dependencies, and then propagate the datatype change.

The Designer performs the following tasks:

  • Updates link path dependencies. The Designer updates the ports in the link path, changing the datatype of the IN_MANUFACTURER_ID port in the Lookup transformation to decimal.
  • Identifies dependent ports. The Designer parses the lookup condition and identifies the MANUFACTURER_ID port in the Lookup transformation as a dependent port.
  • Updates implicit dependencies. The Designer changes the datatype of the MANUFACTURER_ID port in the Lookup transformation to decimal.

Propagated Attributes by Transformation

The following table describes the dependencies and attributes the Designer propagates for each transformation:

Propagated Attributes by TransformationPropagated Attributes by TransformationPropagated Attributes by Transformation

The Designer does not propagate changes to the following mapping objects:

  • Unconnected transformations
  • Reusable transformations
  • Mapplets
  • Source and target instances
  • SDK Source Qualifier

Rules and Guidelines for Propagating Ports and Attributes

Use the following rules and guidelines when you propagate port attributes:

  • The Designer does not propagate to implicit dependencies within the same transformation.
  • When you propagate a port description, the Designer overwrites the description for the port in the other transformations in the mapping.
  • When you propagate backward along the link path, verify that the change does not cause the Integration Service to fail the session. For example, if you propagate changes to a source qualifier, the Integration Service might generate invalid SQL when it runs the session. If you change the port name “CUST_ID” to “CUSTOMER_ID,” the Integration Service might generate SQL to select the wrong column name if the source table uses “CUST_ID.”
  • When you propagate port attributes, verify that the change does not cause the Designer to invalidate the mapping. For example, when you change the datatype of a port from integer to string and propagate the datatype to other transformations, the Designer invalidates the mapping if a calculation uses one of the changed ports. Validate the mapping after you propagate ports. If the Designer invalidates the mapping, click Edit > Revert to Saved to revert to the last saved version of the mapping.
  • When you propagate multiple ports, and an expression or condition depends on more than one propagated port, the Designer does not propagate attributes to implicit dependencies if the attributes do not match.

For example, you have the following expression in an Expression transformation:

Item_desc_out = Substr(ITEM_NAME, 0, 6) || Substr(ITEM_DESC, 0, 6)

The precision of Item_desc_out is 12, ITEM_NAME is 10, and ITEM_DESC is 10. You change the precision of ITEM_DESC to 15. You select parse expressions to infer dependencies and propagate the port attributes of ITEM_NAME and ITEM_DESC. The Designer does not update the precision of the Item_desc_out port in the Expression transformation since the ITEM_NAME and ITEM_DESC ports have different precisions.

Steps to Propagate Port Attributes

Complete the following steps to propagate port attributes.

To propagate port attributes:

  1. Open a mapping in the Mapping Designer, and select one or more ports to propagate.
  2. Click Mappings > Propagate Attributes, and choose Propagate Attributes. Or, right-click the port and choose Propagate Attributes.
  3. The Designer displays the Propagate Port Attributes dialog box.

    Steps to Propagate Port Attributes

    After you open the Propagate Port Attributes dialog box, you can select another port and propagate its attributes.

  4. Select the direction and attributes you want to propagate.
  5. Optionally, to infer dependencies, click Options.
  6. The following table describes the options on the Propagate Port Attributes dialog box:

  7. Click Preview to view the affected ports.
  8. The Designer displays the links to the affected ports in green and the unaffected ports in red.

  9. Click Propagate.
  10. When you propagate port attributes, the Output window displays the propagated attributes and the affected ports.

  11. Click Close.

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

Informatica Topics