You are on page 1of 4

SAP TM BADI Enhancement Procedure

BAdI: Fill Extraction Structures


Use
This Business Add-In (BAdI) is used in the Integration with NetWeaver Business Warehouse
(TM-BW) component.
You can use this BAdI to enhance the extraction structures for the extraction of business
document information from the SAP Transportation Management (SAP TM) system to the SAP
NetWeaver Business Warehouse (SAP NetWeaver BW) system.
If you create an append for an extraction structure of a business document, this BAdI fills the
fields in the append with values from the business document.
You can use the following BAdI methods to enhance the extraction structures:

TOR_BW_EXTRACTION (Transportation Order)

TRQ_BW_EXTRACTION (Transportation Request)

SFIR_BW_EXTRACTION (Freight Settlement Document)

CFIR_BW_EXTRACTION (Forwarding Settlement Document)

BSH_BW_EXTRACTION (Business Share)

TAL_BW_EXTRACTION (Transportation Allocation)

FAG_BW_EXTRACTION (Agreements)

You can also use this BAdI during the delta upload to check, set, or change the records to be
deleted. For more information about the implementation of the delta upload, see BAdI:
Condition for Extraction.
You can use the following BAdI methods to check and set the deletion record:

TOR_BW_EXTRACTION_DELETE (Transportation Order)

TRQ_BW_EXTRACTION_DELETE (Transportation Request)

SFIR_BW_EXTRACTION_DELETE (Freight Settlement Document)

CFIR_BW_EXTRACTION_DELETE (Forwarding Settlement Document)

Standard settings
For more information about the standard settings (filters, single or multiple uses), see the Enh.
Spot Element Definitions tab in the BAdI Builder (transaction SE18).
Activities
For information about implementing BAdIs as part of the Enhancement Concept, see SAP
Library for SAP NetWeaver under BAdIs - Embedding in the Enhancement Framework.

BAdI: Condition for Extraction


Use
This Business Add-In (BAdI) is used in the Integration with NetWeaver Business Warehouse
(TM-BW) component. You can use this BAdI to change the condition for extracting business
document information from the SAP Transportation Management (SAP TM) system to the SAP
NetWeaver Business Warehouse (SAP NetWeaver BW) system.
The system extracts data only for the business document types for which you have selected the
BW Relevance checkbox. For transportation allocations and business shares you define the BW
relevance in the transportation allocations settings.
You cannot use this BAdI to change the BW Relevance setting.
In most cases the system uses the lifecycle status to determine which data to extract. The system
differentiates between the initial upload (with data) and the delta upload.
Standard settings
Initial Upload

During the initial upload, only business documents with a relevant business document specific
lifecycle status are extracted. The following business document-specific lifecycle status values
are relevant for extraction:

Business documents belonging to the Transportation Request business object, for


example, forwarding orders, transportation requirements, with the lifecycle status
Completed.

Business documents belonging to the Transportation Order business object, for example,
freight units, freight bookings, freight orders, service orders, with a lifecycle status that
has the value set in Specify Status for BW Relevance.

Business documents belonging to the Forwarding Settlement Document business object,


for example external forwarding settlement documents, credit memos, with the following
lifecycle status values:

Ready for Invoicing in SAP ERP

Transferred for Invoicing in SAP ERP

Invoiced in SAP ERP

Ready for Credit Memo Creation in SAP ERP

Transferred for Credit Memo Creation in SAP ERP

Credit Memo Created in SAP ERP

Business documents belonging to the Freight Settlement Document business object, for
example freight settlement documents, with the following lifecycle status values:

Ready for Accruals

Transferred for Accruals

Accruals Posted

Invoice Verified in SAP ERP

You can use the following BAdI methods to execute your own logic in the initial upload:

TOR_BW_CONDITION_INIT (Transportation Order)

TRQ_BW_CONDITION_INIT (Transportation Request)

SFIR_BW_CONDITION_INIT (Freight Settlement Document)

CFIR_BW_CONDITION_INIT (Forwarding Settlement Document)

BSH_BW_CONDITION_INIT (Business Share)

TAL_BW_CONDITION_INIT (Transportation Allocation)

FAG_BW_CONDITION_INIT (Agreements)

Delta Upload

During the delta upload, business documents with the following lifecycle status values are
extracted in order to be deleted:

Business documents with the lifecycle status Cancelled.

Business documents whose lifecycle status has changed from the relevant business
document specific lifecycle status for extraction, to another non-business document
specific lifecycle status value.

You can use the following BAdI methods to execute your own logic in the delta upload:

TOR_BW_CONDITION_DELTA (Transportation Order)

TRQ_BW_CONDITION_DELTA (Transportation Request)

SFIR_BW_CONDITION_DELTA (Freight Settlement Document)

CFIR_BW_CONDITION_DELTA (Forwarding Settlement Document)

BSH_BW_CONDITION_DELTA (Business Share)

TAL_BW_CONDITION_DELTA (Transportation Allocation)

FAG_BW_CONDITION_DELTA (Agreements)

If you use one of the above mentioned BAdI methods for the delta upload, you should check
whether the logic for the deletion of a record during the delta upload differs from the standard
settings. You can use a BAdI method to execute this check and to set the records to be deleted.
For more information about the available BAdI methods, see BAdI: Fill Extraction Structures.
Requirements
You have specified that the business document is BW-relevant in one of the following
Customizing activities:

Define Forwarding Order Types

Define Forwarding Quotation Types

Define Freight Order Types

Define Freight Booking Types

Define Freight Unit Types

Define Forwarding Settlement Document Types

Define Freight Settlement Document Types

Define Order-Based Transportation Requirement Types

Define Delivery-Based Transportation Requirement Types

Define Transportation Allocation Settings

Define Freight Agreement RFQ Types

Define Forwarding Agreement RFQ Types

Define Freight Agreement Types

Define FWA and Service Product Catalog Types

Activities
For information about implementing BAdIs as part of the Enhancement Concept, see SAP
Library for SAP NetWeaver under BAdIs - Embedding in the Enhancement Framework.
See also
For more information about the standard settings (filters, single or multiple uses), see the Enh.
Spot Element Definitions tab in the BAdI Builder (transaction SE18).

You might also like