Search This Blog

Wednesday, August 11, 2010

How to use Start Routine in SAP BI Transformation

Many times we required to change the data while loading it to the data target and sometimes need to validate the data and then update them into the target. For this SAP has provided different options in Transformation.

1. Start routine.
2. Field Routine.
3. End Routine.

The idea of writing the routine depends on the requirement. For e.g. if you want to delete records based on some condition then this requirement can be handled at all the places but due to performance reasons it is always better to handle it in the Start routine.

Let me explain how to use Start routine with Scenario

The requirement is to load sales order for only those customers where Industry sector is ‘AFS’ using data source 2LIS_11_VAITM. The industry sector information is not available from data source 2LIS_11_VAITM (Data source to load sales order item data). But, we need to read this information from customer master data as Industry sector is one of the attribute of 0customer.


First create the transformation and hit on Start Routine to open the source code.














Identify the field required from the attribute tab of the info-object (in our case it is 0industry of 0customer)














Different tables of master data info objects are displayed in Master data/Text tab of 0customer info object. We can use /BI0/PCUSTOMER to fetch the industry information out of 0customer info object. Double click on this table will open the table definition in next Screen.














Now identify the field required. Here in our case it is INDUSTRY.














Now we have all the information required to write a start routine. Below is the screen shot showing the routine.














You can fill the monitor entries in case of any errors to trace and fix them.

By

Chindam Praveen Kumar.
Blue Marlin systems.
www.bluemarlinsys.com/bi

4 comments: