Professional Documents
Culture Documents
Informatica Mapping WKF Design Steps
Informatica Mapping WKF Design Steps
1 Introduction. 3-4
Mapplet
A mapplet is a reusable object created in the Mapplet Designer. It contains a set of transformations
and transformation logic that can be reused in multiple mappings. For example, if you have several
fact tables that require a series of dimension keys, create a mapplet containing a series of Lookup
transformations to find each dimension key. You can then use the mapplet in each fact table
mapping, rather than recreate the same lookup logic in each mapping. When you use a mapplet in a
mapping, you use an instance of the mapplet. Like a reusable transformation, any change made to
the mapplet is inherited by all instances of the mapplet.
Include source definition. Use multiple source definitions and source qualifiers to provide
source data for a mapping.
Accept data from sources in a mapping. Use an input transformation to receive source data
from the mapping.
Include multiple transformations. A mapplet can contain as many transformations as you
need.
Pass data to multiple transformations. Each output transformation in a mapplet represents
one output group in a mapplet, to feed data to multiple transformations in the mapping.
Contain unused ports. Do not have to connect all mapplet input and output ports in a
mapping.
Mapplet Input
Mapplet input can originate from a source definition and/or from an Input transformation in the
mapplet.
Use one or more source definitions in a mapplet to provide source data. When you use such a
mapplet in a mapping, it is the first object in the mapping pipeline and contains no input ports.
Use an Input transformation in a mapplet when you want the mapplet to receive input from a source
in a mapping. When you use the mapplet in a mapping, the input transformation provides input ports
so you can pass data through the mapplet. Each port in the Input transformation connected to another
transformation in the mapplet becomes an input port of the mapplet. Input transformations can
|
Page 3
receive data from a single active source. Unconnected ports do not display in the Mapping Designer.
You can connect an Input transformation to multiple transformations in a mapplet. However, you
cannot connect a single port in the Input transformation to multiple transformations in the mapplet.
Mapplet Output: Use an output transformation in a mapplet to pass data through the mapplet into a
mapping. A mapplet must contain at least one output transformation with at least one connected port
in the mapplet. Each connected port in an output transformation displays as a mapplet output port in
a mapping. Each output transformation in a mapplet displays as an output group in a mapping. An
output group can pass data to multiple pipelines in a mapping.
Mapplet Port: Mapplet ports display only in the Mapping Designer. Mapplet ports consist of input
ports from input transformations and output ports from output transformations. If a mapplet uses
source definitions rather than input transformations for input, it does not contain any input ports in
the mapping.
1. Create a mapplet. Click Mapplets > Create from the menu in the Mapplet Designer. The
recommended naming convention for mapplets is mpltMappletName.
2. Create mapplet transformation logic. Create and link transformations in the same manner as in
a mapping.
The Designer automatically validates a mapplet when you save it. You can also validate a mapplet
using the Mapplets > Validate menu command. The Designer validates the mapplet pipeline in the
same way it validates a mapping. In addition, the Designer performs the following checks specific to
mapplets:
The mapplet should contain Input transformations and/or source definitions with at least one
port connected to a transformation in the mapplet.
The mapplet should contain at least one Output transformation with at least one port
connected to a transformation in the mapplet.
Editing Mapplets
You can edit a mapplet in the Mapplet Designer. When you save changes to a mapplet, all instances
of the mapplet and all shortcuts to the mapplet inherit the changes. These changes may invalidate
mappings that use the mapplet. You can make the following changes to a mapplet without affecting
the validity of existing mappings and sessions:
In a mapping, a mapplet has input and output ports that you can connect to other transformations in
the mapping. You do not have to connect all mapplet ports in a mapping. However, if the mapplet
contains an SQL override, you must connect all mapplet output ports in the mapping.
Description
In this example, we remove duplicate row using mapplet. There are following steps to remove
duplicate row using mapplet
.
Create Repository and Folder in Informatica Repository Manager.
Import Source database and create/import target table in Informatica Designer.
Create mapplet, First create input mapplet (creating port for input the column), then create
aggregator transformation (add dummy port for column and check group by box to this
column and then count data using count function). Then create filter transformation and filter
the unique and duplicate data using expression. Then passes all column into output mapplet
transformation.
Then Create Mapping using mapplet.
Create workflow and execute workflow.
Check log file.
Then Review output data.
|
Duplicate Records
Creating Repository and Folder
Step-1 First create repository, Click on Start -> All Programs -> Informatica 9.0.1 -> Client -> Power
Center Client -> Power Center Repository Manager.
Step-3 Give information like Repository Name and Username. Then click on ok button and
repository created successfully.
Step-4 Now connect repository. Right click on newly created repository and click on connect.
Creating Folder.
Step-1 Go to Informatica Power Center Repository Manager and click on Folder Menu and click on
Create.
|
Page 9
Step-2 Specify Name of Folder, Description, Owner, OS Profile, Options, Status and got to
permissions tab.
|
Page 10
Step-4 This is newly created Folder
Importing Source and Target Table
Step-1 Click on Start -> All Programs -> Informatica 9.0.1 -> Client -> Power Center Client -> Power
Center Designer..
Step-2 Then Connect to Repository in Informatica Power Center Designer Right click on repository
name and click on Connect.
Step-3 Go to Tools Menu and click on Source Analyzer to import source table. And then go to
Sources Menu in Informatica Power Center Designer.
Step-4 And then select Source menu and click on Import from database
Step-5 Specify Username, Owner name, password and then connect. Then select source table and
click OK.
Step-6 View data in source analyzer, Right click on SRC_CREDITCARD and select Preview Data.
Step-7 Specify Username and Password and connect it. Then Close it.
Step-8 Now click on Target Designer.
Step-9 And then select Target menu and click on Import from database to import target table.
Step-10 Specify Username, Owner name, password and then click on connect and then select table
and then OK.
Step-11 To view data select table and Right click on that table after that specify Username and
Password and connect it. Then Close it.
Step-12 To view data select table and Right click on that table after that specify Username and
Password and connect it. Then Close it.
CREATE MAPPLET & MAPPING
Step-1 Go to Mapplet Designer and Create New Mapplet and then name of mapplet and click
OK.
Step-3 Then select Mapplet Input transformation in list and name on transformation.
Step-4 Mapplet Input Transformation.
Step-7 Then create aggregator transformation, click on transformation menu ant select create then
select aggregator in transformation drop down and name of transformation.
Step-8 Then passes all column into aggregator table and right click on aggregator table and select
Edit.
Step-9 In ports tab create dummy port for account_officer_cd and name of port and in expression
write query as a count(account_officer_cd).
Step-10 Then create two filter transformation, passed all row into filter table.
Step-11 Then right click on filter transformation and select Edit, Then go to properties tab and write
filter condition.
Step-11 Write Condition and Validate it.
Step-12 Then right click on second filter transformation and select Edit, Then go to condition and
write condition.
Step-13 Write Condition and Validate it.
Step-17 Then go to Mapping Designer and Create New Mapping and then name of mapping
and click OK.
Step-18 Then drag and drop source and target data in Mapping Designer.
Step-19 Then drag and drop mapplet into Mapping Designer Window.
Page 35
Step-21 And connect output to target table.
Step-1 Now go to Informatica Power Center Workflow Manager, and go to Tools menu and select
Workflow Designer.
Step-2 Now to create workflows, Go to Workflows menu and select Create. After that Name of
workflow and click OK buttons.
Page
Step-3 Now create Task, Go to Tasks Menu and click Create.
Step-7 Now create flow B/W Workflow to Task. Select Line Task and link to Start to Filter.
Step-9 Now Configure Connection to Source and Target, Then Right Click on Unique_Records and
select Edit, Then Click Mapping tab and configure connection for your source and target table
schema in oracle 11g RDBMS. And then click OK.
Step-10 Select DBConnection for Source and Target Relation Database and set property on Target
Connection.
Page 41
Step-11 Now save (ctrl+s) this workflow and check it.
Page 42
WORKFLOW MONITOR AND VIEW TARGET DATA
Step-1 Now Start Workflow, Right click on Workflow Designer Window and Click on Start
Workflow.
Page 43
Step-3 Now view data in Target RDBMS (Oracle 11g)
Unique Records
Duplicate Records
Page 44
Rules and Guidelines for Usage of Mapplets
You can connect an Input transformation to multiple transformations in a mapplet. However, you
cannot connect a single port in the Input transformation to multiple transformations in the mapplet.