上QQ阅读APP看书,第一时间看更新
Using the expression editor
To manipulate the date, we need to write the functions in the ports. You can use the functions provided from the list of functions inside the expression editor.
- Click on the icon as shown in the following screenshot to open the expression editor:
- New windows will pop up where you can write the function. From the Functions tab, you can use functions. Informatica PowerCenter provides all the functions that cater to the need of SQL/Oracle functions, mathematical functions, trigonometric functions, date functions, and so on.
- In our scenario ,we need to use the CONCAT function. Double-click on the Concat function under the list of functions to get the function in the editor as shown in the following screenshot:
- Click on Ports in the expression editor, and double-click on FIRST_NAME and LAST_NAME to get the function as shown in the following screenshot:
- As you can notice in the preceding screenshot, the expression editor provides a numeric keypad and an operator keypad that can be used to write the functions.
- Once you complete writing the function, click on Validate to make sure the function is correct syntactically. Click on OK.
- Similarly, write the function for calculating TOTAL_SALARY, which is JAN_SAL+FEB_SAL.
- Link the corresponding ports to the target as shown in the following screenshot:
- Save the mapping to save the metadata in the repository. With this, we are done with creating the mapping using expression transformation. We have also discussed the ports and learned how to use the expression editor. You also learned how to write the function in transformation. These details will be used across all other transformations in Informatica.