What is Expression Transformation in Informatica -Technical Teacher
What is the Expression Transformation?
This Transformation is used for row level manipulations.
It is used for various types of function like CONCAT, TO_DATE ,TO_CHAR etc.
It processes the data in row wise manner.
Let us take one example-
We have student data.
In source, we have Student_ID, First_name, Last_Name, Age, Address, Mobile_No.
We need data in target as shown in figure.
We need to combine Name of First_name and Last_Name .
I have connected all column names of source to all column names of target.
When we connect first_name to full_name then the mapping is valid. But if we try to connect Last_name to full_name it will throw an error.
In informatica, you cannot connect multiple columns into one column.
We need to concatenate the First_name and Last_Name by using this Transformation.
Creating mapping with Expression Transformation-
- Drag and Drop both source and target to mapping.
You have noticed, with source one default transformation is there Source Qualifier. Then you can create the expression Transformation.
How to create Expression Transformation?
1-Click Transformation on toolbar
2-Click Create
3-Select the Expression and give the name of this Expression.
4-Drag it all these columns from source Qualifier to expression Transformation.
5-Add one new column “Full_name“ in Expression.
6-You can unchecked the Output Port of First_name and Last_Name and disable the Input Port of Full_Name.
7-Write the function — CONCAT.
CONCAT(First_name, Last_Name) for Full_Name
Click validate for checking this function is correct or not.
8-You can connect new column “Full_name“ from Expression to target column “Full_name“.
9-You can save the mapping à Ctrl+S
10-Now,your mapping is valid. Create the session and workflow for this mapping.
- Run the workflow.
- You will get desire output in Full_Name column.