You are on page 1of 23

Step-by-Step tutorial to upload Master Data from Flat File (SourceSystem) to InfoObjects (Master data table)

By Lakshmi MP, Perot Systems

Basic Steps of Data Flow (ETL process): 1. Determine the Source System (Flat File/SAP R3/WebServices etc) 2. Establish an interface w.r.t the Source system used 3. Create a Data Source which has a structure similar to the Source structure. Consider two factors : Name of file and Structure same as Source. 4. Create Info Provider to transfer data from Data Source to PSA (Persistent staging Area) 5. Create a Target (Info Provider : InfoObjects/Info Cubes/DSO etc) 6. Create a Transformation rule to map Source & Target fields. 7. Create DTP (Data Transfer Process) to transport data stored within PSA , to the final Data Target. Transaction Code RSA1 : Data Warehouse Workbench

Source/Input: Create a Flat File of type CSV, with the following structure: Custome r 260 261 262 Language EN DE DE Land US DE DE City SEATTLE HAMBURG WALDORF Name JOHN SAM MICHEAL

Right click on the InfoProvider column header. Select Create InfoArea

Enter the details InfoArea name and Description

The InfoArea IA for Customer appears on the InfoProvider list. Right click on the created InfoArea and create InfoObject Catalog

Enter a suitable Name and Description for InfoObject Catalog. Select Char. or Key Figure based on the type of data (Master data/ Trans. Data) needs to be created. In this case, we are creating Master data. Hence, we need to create Characteristics InfoObject. Select Char. Click on Create. The InfoObject Catalog appears right under the InfoArea created earlier. Now, right click on the InfoObject Catalog and create Info Object.

In the pop-up for InfoObject enter Characteristic name and description. The first Characteristic InfoObject created can be treated as a key value in the Master table to be created. On the right window, the properties of the Characteristic CUSTNO are visible. In the General Tab, enter the Data Type and Length.

Note: the Attribute Only field is not checked. This means that this Characteristic is a primary key field in the Master Data table. If the box is checked, then it becomes an attribute of this Characteristic Key field or just another normal field in the Master data Table. In the Business Explorer tab, no changes to be done.

Save + Activate => P tables gets created In the Master data/texts tab, Check With Master data, to create a Master Data table, having naming convention /BIC/P<characteristic name> Check With Texts, to create a corresponding Text table for this Master Data table with two default fields Language & Description. Select short/medium/long texts, also texts language dependent. Select Char is InfoProvider (as our InfoObject is our target in this scenario). Enter the InfoArea in the box below.

In the Attribute tab, enter the fields (non-key fields) that need to be maintained within the Master Data table.

Ex: Customer Id primary key field Land City

On entry of each field, hit [Enter] and in the pop-up box, select the 1st option Create Attribute as Characteristic.

Enter the Data type and the Length. [Enter] Repeat the same for other fields too.

[Activate ] - Activate all dependent InfoObjects. Create File Interface: Source Systems File Create <New File System> Or Use the existing file source system

Data Source creation/selection: On the Navigator tab, select Data Source. Click on the [X] button to Choose the Source System.

Choose the Source System File <Flat File source system name>

Right click on the header and Create Application Component.

Enter the name and description for Application Component. Ex: Name: APC_CUSTOMER Click ok. The technical name of Application component APC_CUSTOMER now gets saved as => ZAPC_CUSTOMER Right click on the Application component and create DataSource

Enter a suitable DataSource name : DS_Cust Source System : Flatfile Select Data Type of DataSource : Master Data attributes as we are creating master data table. Note: Select Master Data Attributes, while you are uploading Master Data from file (DS1) Select Master Data Text, while you are uploading Text Descriptions for the Master Data records (DS2)

In the right Window, you can view the Data Source properties. General Info tab provides information on the Data Source created Extraction tab provides details of file to be extracted. In a Data source, we need to mention 2 details: Name of Flat File (ASCII or CSV) to be uploaded Structure (Layout) of the input file, mentioning the fields.

Therefore, make the following changes: - Select name of file using F4, search for the file on you local desktop - Header rows to be ignored = 1 (if file has a header row as column titles) = 0 (if file has no header row) - Select Data Format as Separated with Separator (for ex CSV). Enter the Data Separator as , .

Proposal tab provides a quick view of the data in the flat file to be uploaded Click on the Load Example tab. The details can be viewed in the below pane.

Fields tab provides details of all fields used to create a data structure, to map with the fields from Source file. In the Template Info field, enter the field names (characteristics/attributes). [Enter] or [Save] [Copy] : all properties of the characteristics ( ex: data types, length etc) are copied here.

Note: the fields 0LANGU and 0TXTSH are the standard SAP defined characteristics InfoObjects. [Save] [Activate]

Preview tab gives a preview of data on flat file loaded onto a structure. Click on Read Preview Data

Info Package: An InfoPackage helps to transport data from the Data Source structures into the PSA tables. (This is similar to transfer of data from Work areas to Internal Tables in R/3 ABAP). Rt. Click on the Data Source and Create InfoPackage.

Enter the InfoPackage name : IP_Cust Enter a suitable Description Select the corresponding DataSource from the list below and [Save].

On the right window, we have the InfoPackage properties: Data Selection tab to initiate loading of data into the infopackage Select Start Data Load Immediately Click on [Start]. Then click on the [Monitor]button next to Process Chain Mgmt Or [ F6].

In the next screen, we can view the status of the data loading to PSA. Click on the [PSA Maintenance] or [Ctrl + F8] to maintain the PSA table with the flat file values.

In the pop-up, defining the number of records per request, click OK.

This leads to the PSA display screen, with the table and the respective data in them. Click on [Back] and come back to the DataSource screen. Transformation: This is a rule that is defined, for mapping the source fields in the DataSource to the final Target (basically, the Info Providers from where BI extracts the reports). In this case, our target is the InfoObject (Master data table), which has been already created. Note: Normally, the Transformation can be created on the Data Source or the Target. Here, we are creating a Transformation on the DataSource. Right click on DataSource Create Transformation

In the pop-up, For the Target of Transformation, - Enter Object Type: InfoObject (this is our target in this scenario) - Enter subtype of Object: Attributes (as were considering Master data only. Not transactional data) - Enter the name of the InfoObject we created. For the Source of Transformation, - Enter Object Type: DataSource (this is our source structure) - Enter name of Data Source used - Enter the Source System used. Click on OK Note: While uploading Master Data, select Sub-type of Object : Attributes (IP1 for DS1) While uploading Text desc. For this Master Data, select Subtype of Object : Texts (IP2 for DS2)

In the next screen pop-up, we get the no. of proposals (rules) generated to map source fields with target fields. Click on Ok.

On the next window we can see a graphical representation of the mapping of Source fields to Target fields. Save and Activate, if the mapping if done correctly.

Data Transfer Process (DTP): The DTP is a process used to transfer data from the PSA tables, into the data Targets, based on the Transformation (mapping) rules. DataSource right click Create Data Transfer Process.

In the pop-up, The DTP name is described as : < DataSrc/SourceSys -> InfoObject > DTP type : standard Target of DTP : Object Type : InfoObject (in this case) Subtype of Object : Attribute Name : < name of InfoObject > Source of DTP: Object Type : Data Source DataSource : <name> Source System: Flat file Click on OK.

In the DTP properties window,

Extraction tab, - Select Extraction Mode as Full.

[Save] [Activate]

Update tab no changes to be made Execute tab, - Click on [Execute] button

Click on [Refresh] until the icons in Yellow, turn Green. Incase a Red icon appears, we need to track the error and rectify it. Go Back. To view the contents of the Target (Info Object), there are 2 ways:

1. Go to the InfoObject CUSTNO MasterData/Texts tab Dbl click on the Master data table created :
/BIC/P<Char name> Table display Execute

On Transformation/DTP Attribute rt.click Manage rt windw Contents tab [Contents] F8.

Text table Data Display is Language Dependent: For Lang = EN, display corresponding Short Desc.

For Lang = DE, display corresponding Short Desc.

Observations: In the above Master data table display, The fields Customer Name, Customer Land, Customer City : have been created and loaded with data as per the file. These 3 fields have been created as a result of checking the With Master data for the Characteristic. The contents of the Master data are stored in the newly created transparent table /BIC/P<char. Name> Ex:

The fields Language , Description : have been created and loaded with data as per the file. These 2 fields have been created by default, as a result of checking the With Text data for the Characteristic. The contents of the Text data are stored in the newly created transparent table /BIC/T<char. Name> Ex:

You might also like