SAP BAPI_WARRANTYCLAIM_CHANGE2 Function Module for Change Warranty Claim
BAPI_WARRANTYCLAIM_CHANGE2 is a standard bapi warrantyclaim change2 SAP function module available within SAP R/3 or S/4 Hana systems, depending on your version and release level. It is used for Change Warranty Claim processing and below is the pattern details for this FM, showing its interface including any import and export parameters, exceptions etc. there is also a full "cut and paste" ABAP pattern code example, along with implementation ABAP coding, documentation and contribution comments specific to this or related objects.
See here to view full function module documentation and code listing for bapi warrantyclaim change2 FM, simply by entering the name BAPI_WARRANTYCLAIM_CHANGE2 into the relevant SAP transaction such as SE37 or SE38.
Function Group: WTY12
Program Name: SAPLWTY12
Main Program: SAPLWTY12
Appliation area:
Release date: 27-Mar-2013
Mode(Normal, Remote etc): Remote-Enabled
Update:
Function BAPI_WARRANTYCLAIM_CHANGE2 pattern details
In-order to call this FM within your sap programs, simply using the below ABAP pattern details to trigger the function call...or see the full ABAP code listing at the end of this article. You can simply cut and paste this code into your ABAP progrom as it is, including variable declarations.CALL FUNCTION 'BAPI_WARRANTYCLAIM_CHANGE2'"Change Warranty Claim.
EXPORTING
CLAIM = "Number of Warranty Claim
CLAIM_HEADER = "Warranty Claim Header Data
* BADI_CHANGE = 'X' "Run Through BADI WTY_CREATE_COPY 'X' = Yes
* SIMULATE = ' ' "Simulation Mode
* READFROMBUFFER = ' ' "Read from Temporary Data Buffer
* IV_LOG_DISMISS = ' ' "General Indicator
TABLES
* CLAIM_VERSION = "Warranty Claim Version
* CLAIM_OBJECT_UPDATE = "Warranty Claim Change Information Header/Version/Item
* CLAIM_PARTNER = "Partner for Warranty Claim
* CLAIM_ITEM = "Warranty Claim Item
* CLAIM_TEXT = "Long Texts for Warranty Claim
* CLAIM_MEASURE = "Warranty: Measurement Data for Object and Claim
* CLAIM_PRICING = "Prices Belonging to Warranty Claim
* VERSION_REL = "Warranty Claim: Relationship Between Versions
* ITEM_REL = "Warranty Claim: Relationship Between Items
RETURN = "Return Parameters
* EXTENSIONIN = "Customer Enhancment Import
IMPORTING Parameters details for BAPI_WARRANTYCLAIM_CHANGE2
CLAIM - Number of Warranty Claim
Data type: BAPI2222HEADER-CLAIMOptional: No
Call by Reference: No ( called with pass by value option)
CLAIM_HEADER - Warranty Claim Header Data
Data type: BAPI2222HEADERCHANGEOptional: No
Call by Reference: No ( called with pass by value option)
BADI_CHANGE - Run Through BADI WTY_CREATE_COPY 'X' = Yes
Data type: BAPI2222HEADERCHANGE-BADICHANGECALLDefault: 'X'
Optional: Yes
Call by Reference: No ( called with pass by value option)
SIMULATE - Simulation Mode
Data type: BAPI2222HEADER-SIMULATIONDefault: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)
READFROMBUFFER - Read from Temporary Data Buffer
Data type: BAPI2222HEADER-FROMBUFFERDefault: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)
IV_LOG_DISMISS - General Indicator
Data type: BAPI2222HEADER-IV_LOGDefault: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)
TABLES Parameters details for BAPI_WARRANTYCLAIM_CHANGE2
CLAIM_VERSION - Warranty Claim Version
Data type: BAPI2222VERSIONCHANGEOptional: Yes
Call by Reference: Yes
CLAIM_OBJECT_UPDATE - Warranty Claim Change Information Header/Version/Item
Data type: BAPI2222UPDATEOptional: Yes
Call by Reference: Yes
CLAIM_PARTNER - Partner for Warranty Claim
Data type: BAPI2222PARTNEROptional: Yes
Call by Reference: Yes
CLAIM_ITEM - Warranty Claim Item
Data type: BAPI2222ITEMCHANGEOptional: Yes
Call by Reference: Yes
CLAIM_TEXT - Long Texts for Warranty Claim
Data type: BAPI2222LONGTEXTOptional: Yes
Call by Reference: No ( called with pass by value option)
CLAIM_MEASURE - Warranty: Measurement Data for Object and Claim
Data type: BAPI2222MEASUREOptional: Yes
Call by Reference: No ( called with pass by value option)
CLAIM_PRICING - Prices Belonging to Warranty Claim
Data type: BAPI2222PRICINGOptional: Yes
Call by Reference: No ( called with pass by value option)
VERSION_REL - Warranty Claim: Relationship Between Versions
Data type: BAPI2222VERSIONRELATIONOptional: Yes
Call by Reference: No ( called with pass by value option)
ITEM_REL - Warranty Claim: Relationship Between Items
Data type: BAPI2222ITEMRELATIONOptional: Yes
Call by Reference: No ( called with pass by value option)
RETURN - Return Parameters
Data type: BAPIRET2Optional: No
Call by Reference: No ( called with pass by value option)
EXTENSIONIN - Customer Enhancment Import
Data type: BAPIPAREXOptional: Yes
Call by Reference: No ( called with pass by value option)
Copy and paste ABAP code example for BAPI_WARRANTYCLAIM_CHANGE2 Function Module
The ABAP code below is a full code listing to execute function module POPUP_TO_CONFIRM including all data declarations. The code uses the original data declarations rather than the latest in-line data DECLARATION SYNTAX but I have included an ABAP code snippet at the end to show how declarations would look using the newer method of declaring data variables on the fly. This will allow you to compare and fully understand the new inline method. Please note some of the newer syntax such as the @DATA is not available until a later 4.70 service pack (SP8), which i why i have stuck to the origianl for this example.DATA: | ||||
lv_claim | TYPE BAPI2222HEADER-CLAIM, " | |||
lt_claim_version | TYPE STANDARD TABLE OF BAPI2222VERSIONCHANGE, " | |||
lt_claim_object_update | TYPE STANDARD TABLE OF BAPI2222UPDATE, " | |||
lt_claim_partner | TYPE STANDARD TABLE OF BAPI2222PARTNER, " | |||
lt_claim_item | TYPE STANDARD TABLE OF BAPI2222ITEMCHANGE, " | |||
lv_claim_header | TYPE BAPI2222HEADERCHANGE, " | |||
lt_claim_text | TYPE STANDARD TABLE OF BAPI2222LONGTEXT, " | |||
lv_badi_change | TYPE BAPI2222HEADERCHANGE-BADICHANGECALL, " 'X' | |||
lv_simulate | TYPE BAPI2222HEADER-SIMULATION, " SPACE | |||
lt_claim_measure | TYPE STANDARD TABLE OF BAPI2222MEASURE, " | |||
lt_claim_pricing | TYPE STANDARD TABLE OF BAPI2222PRICING, " | |||
lv_readfrombuffer | TYPE BAPI2222HEADER-FROMBUFFER, " SPACE | |||
lt_version_rel | TYPE STANDARD TABLE OF BAPI2222VERSIONRELATION, " | |||
lv_iv_log_dismiss | TYPE BAPI2222HEADER-IV_LOG, " SPACE | |||
lt_item_rel | TYPE STANDARD TABLE OF BAPI2222ITEMRELATION, " | |||
lt_return | TYPE STANDARD TABLE OF BAPIRET2, " | |||
lt_extensionin | TYPE STANDARD TABLE OF BAPIPAREX. " |
  CALL FUNCTION 'BAPI_WARRANTYCLAIM_CHANGE2' "Change Warranty Claim |
EXPORTING | ||
CLAIM | = lv_claim | |
CLAIM_HEADER | = lv_claim_header | |
BADI_CHANGE | = lv_badi_change | |
SIMULATE | = lv_simulate | |
READFROMBUFFER | = lv_readfrombuffer | |
IV_LOG_DISMISS | = lv_iv_log_dismiss | |
TABLES | ||
CLAIM_VERSION | = lt_claim_version | |
CLAIM_OBJECT_UPDATE | = lt_claim_object_update | |
CLAIM_PARTNER | = lt_claim_partner | |
CLAIM_ITEM | = lt_claim_item | |
CLAIM_TEXT | = lt_claim_text | |
CLAIM_MEASURE | = lt_claim_measure | |
CLAIM_PRICING | = lt_claim_pricing | |
VERSION_REL | = lt_version_rel | |
ITEM_REL | = lt_item_rel | |
RETURN | = lt_return | |
EXTENSIONIN | = lt_extensionin | |
. " BAPI_WARRANTYCLAIM_CHANGE2 |
ABAP code using 7.40 inline data declarations to call FM BAPI_WARRANTYCLAIM_CHANGE2
The below ABAP code uses the newer in-line data declarations. This allows you to see the coding differences/benefits of the later inline syntax. Please note some of the newer syntax below, such as the @DATA is not available until 4.70 EHP 8."SELECT single CLAIM FROM BAPI2222HEADER INTO @DATA(ld_claim). | ||||
"SELECT single BADICHANGECALL FROM BAPI2222HEADERCHANGE INTO @DATA(ld_badi_change). | ||||
DATA(ld_badi_change) | = 'X'. | |||
"SELECT single SIMULATION FROM BAPI2222HEADER INTO @DATA(ld_simulate). | ||||
DATA(ld_simulate) | = ' '. | |||
"SELECT single FROMBUFFER FROM BAPI2222HEADER INTO @DATA(ld_readfrombuffer). | ||||
DATA(ld_readfrombuffer) | = ' '. | |||
"SELECT single IV_LOG FROM BAPI2222HEADER INTO @DATA(ld_iv_log_dismiss). | ||||
DATA(ld_iv_log_dismiss) | = ' '. | |||
Search for further information about these or an SAP related objects