How To Extract Batch Master Data Via Generic and Classification Datasource To BW PDF
How To Extract Batch Master Data Via Generic and Classification Datasource To BW PDF
Applies to:
SAP ECC 5.0 and above releases and BW 7.0
Summary
This paper gives a detail understanding on how to extract Batch master data (Batch Attributes and Batch
Classification) from ECC to BW. This document would provide step by step guide to create a generic (view
based) datasource and Batch Classification datasource.
Author Bio
Devesh Laad is SAP Certified Netweaver 2004s BI Solution Consultant. He has more than 7 yrs
experience in SAP BW and has worked on SAP BW 3.0b, 3.5 and 7.0 versions.
Table of Contents
Introduction ......................................................................................................................................................... 3
Basic understanding of where Batch master data resides in ECC ................................................................. 3
Overview of Batch Datasources – Generic View Datasource and Classification Datasource ........................ 3
Step By Step Procedure ..................................................................................................................................... 4
Related Content ................................................................................................................................................ 13
Disclaimer and Liability Notice .......................................................................................................................... 14
Introduction
Batch master data attributes is frequently required for data modeling in BW. Batch data is also sometime
configured as Classification data based on project needs. In our example, Batch management is Cross-
Plant.
There is no standard business content datasource available for batch master data attributes extraction.
For us to extract Batch Classification data, we need to first create a generic datasource (either View based or
Function module) which would extract Batch master data attributes. Using this generic datasource as Basis
datasource, we would generate Batch Classification datasource.
This document is focused on creation of generic datasource (View based) to extract batch master data
attributes datasource and batch classification datasource and its load to custom infoobject in BW.
Enter description for view. Include all fields from MCH1 table in ‘View Flds’ tab.
Select ‘Extraction from View’ and fill the required description and View ZV_MCH1. Click Save.
Select ‘Selection Fields’ as CHARG, ERDSA, LAEDA and MATNR. Save datasource.
Double Click on ‘Characteristics’ folder to enter characteristics of Batch class that you want to
extract.
In Type column enter either ‘CHA’ for characteristic fields or ‘KYF’ for key figure fields.
Initially when the datasource is being created the column ‘Maint’ will have value ‘N’. The ‘R’ status
indicates that the classification datasource is ready and is achieved after generation. If one changes
a characteristic, then we must reset the status to ‘N’ before generation.
Generate Datasource.
3. Create a custom infoobject ZBATCH in BW and assign relevant infoobjects as attributes (which map
to fields of datasource ZDS_BATCH and 1CL_ODS_001). Assign 0MATERIAL as the compounded
infoobject (as in our example Batch management is Cross-Plant).
Create two transformations. One from RSDS ZDS_BATCH -> IOBJ ZBATCH and second RSDS
1CL_ODS_001 -> IOBJ ZBATCH with relevant direct mapping between fields of datasource and
attribute infoobjects of ZBATCH.
Make sure that you map fields MATNR, CHARG, ERDSA and LAEDA are assigned from datasource
ZDS_BATCH.
To extract delta for Batch datasource (ZDS_BATCH), we would need to load data from two
infopackages. One infopackage will load new data based on ERDSA field (Created On) and another
infopackage will load changed records based on field LAEDA (Changed On).
Both infopackages have update mode as ‘Full’ Update. However, we generate pseudo delta by
writing a small ABAP routine for fields ERDSA and LAEDA in different infopackages to extract data
for the current day based on system date.
The second transformation is between datasource RSDS 1CL_ODS_001 and ZBATCH infoobject.
Make necessary direct mappings between datasource fields (batch class fields) and attribute
infoobjects of characteristic ZBATCH.
The classification datasource automatically generates delta and hence we load this data via a single
infopackage with Delta update. We need to perform Initialize Delta load the first time and then
followed by Delta loads daily.
Related Content
http://help.sap.com/printdocu/core/Print46c/en/data/pdf/LOBM/LOBM.pdf
http://wiki.sdn.sap.com/wiki/display/ERPLO/Batch+Management