Enhancing Business Content using SAP BW

The transaction data entering the Business Information Warehouse by means of extractors originates from very different modules. Due to past developments, very different extraction mechanisms are necessary.

Business Scenario

Your company wants to include the old material number as an additional characteristic for certain Data Sources from logistics. Some of the standard extractors will have to be modified as a result. You decide to enhance these extractors in Business Content.

Your company also wants the materials assigned to a class of type '001' in the OLTP System to be displayed as such in the material reports carried out in BW. Here too, you decide to enhance Business Content (0MATERIAL).

Enhancing Info Sources in Business Content

Reasons:

  1. You want to add further attributes to the characteristics (master data) shipped with the system.
  2. You want to integrate additional characteristics in the DataSources for transaction data that are shipped with the system.

Prerequisites:

  1. The additional data is available when the extraction function is carried out.
  2. All of the keys required to read the additional data are part of the original data.

Data Enhancement in the Extraction Path

Time of statistics update

Information systems such as the LIS or CO-PA allow you to enhance characteristics that are not contained in the documents by means of enhancements or other methods. Such characteristics are therefore always generated at the time when a document is posted. 

Time of transaction data extraction (customer specific)

When the transaction data is loaded from the OLTP systems to the BW System, fields that cannot be supplied with data by the documents are populated by means of a special enhancement. The customer determines when the data is enhanced, since it depends on the point at which the data is extracted.

Time of master data extraction (customer specific)

Similarly, when master data is extracted, fields that cannot be supplied with data via the extractor are enriched by means of an enhancement when the data is loaded into BW. The customer determines when the data is enhanced here too, since it depends on the point at which the data is extracted. 

The time for extracting texts and hierarchies is the same as for transaction and master data extraction.


Enhanced Transaction Data Extraction

If your requirements are not covered completely by the Data Sources supplied with Business Content, you can obtain additional information in the extraction routine by developing your own program and integrating it in a function enhancement.

Note the following four steps
1. Define the required fields in an append structure that is appended to the extract structure of your Data Source.
2. Write your function exit to call up the relevant data sources for your Data Source.
3. Replicate the Data Source in BW.
4. Extract the data for your 'enhanced Business Content'.





Creating and Maintaining Customer Appends

In the IMG for BW (transaction SBIW), choose Business Information Warehouse > Subsequent processing of Data Sources > Edit Data Source
First, you have to generate the customer append for the extract structure of your Data Sources. To do so, the system proposes a name starting with 'ZA' followed by the name of the extract structure. 

Then maintain the fields that you want to enhance later. All of these fields should start with 'ZZ'. 
Finally, generate your append structure.



Developing Function Enhancements

in the second step, you must define the function enhancement for filling the new fields in the extract  structure.You have to create a project before you can use an enhancement like this. You can then  integrate one or more enhancements into this project. For our task, SAP provides the enhancement RSAP0001.Remember that an enhancement cannot be used in two projects simultaneously.

There are four different enhancement components that can be used for the enhancement RSAP0001. Their INCLUDEs contain the code for filling the extract structure. 


  1. EXIT_ SAPLRSAP_001 Transaction data supply
  2. EXIT_ SAPLRSAP_002 Master data and text supply 
  3. EXIT_ SAPLRSAP_003 Texts supply (Functionality as of BW 2.0B available with EXIT_SAPLRSAP_002!) EXIT_ SAPLRSAP_004 Hierarchy supply


Every enhancement project has documentation, which also explains the individual parameters of the function module. To display documentation on the entire enhancement, choose Utilities > Display entire document  in the Project Management of SAP Enhancements transaction (CMOD).


Sample Coding

Important: always use a CASE statement to interrogate the Data Source, since this function exit is called with every Data Source.




Troubleshooting in Enhancements

Extractors are executed as background tasks. This means that breakpoints do not have any effect.

Prerequisite

  1.  Development authorization in the source system
  2. Troubleshooting authorization in the source system


Required steps

  1. Add and/or activate an endless loop in the extractor
  2. Log on to the source system
  3. Monitor running tasks (SM50)
  4. Start extraction with the Scheduler in BW
  5. Locate the process in the Monitor and start troubleshooting 

Restart the Administrator Workbench after coding changes in the Customer Exit

When monitoring the source system, make sure that the extractor is called with the ALE user.As an alternative troubleshooting method, you can use breakpoints to detect errors in the enhancement. This procedure is described in greater detail in note 123085.


  1. Once the function exit is used, it is called up with each extraction ('CASE' statement required).
  2. Key fields for the enhanced Content must be available.
  3. User exit is only intended for append fields.
  4. Do not change the field contents and do not add data records!
  5. The maximum field length is 32 characters.
  6. Are all of the recommended units of measure included?
  7. Further documentation is provided under the transaction CMOD.



Related Posts

No comments :

Post a Comment