Professional Documents
Culture Documents
SAP PP Extending BAPI Function Module BAPI - ALM - ORDER - MAINTAIN' - SAP Blogs
SAP PP Extending BAPI Function Module BAPI - ALM - ORDER - MAINTAIN' - SAP Blogs
SAP PP Extending BAPI Function Module BAPI - ALM - ORDER - MAINTAIN' - SAP Blogs
Community Topics Groups Answers Blogs Events Programs Resources What's New Explore SAP
Former Member
August 9, 2012 | 2 minute read
Follow This document helps how to extend the BAPI function module ‘BAPI_ALM_ORDER_MAINTAIN’ for Z fields.
In order to extend the BAPI, we should have EXTENSION_IN table which is type of BAPIPAREX.
Like
Please follow the below steps to extend the BAPI.
RSS Feed 1. In AUFK table, we have custom include with name ‘CI_AUFK’. So add the Z field ZZLEG_PM_ORD in structure CI_AUFK and activate it. Now we have a custom field
ZZLEG_PM_ORD in standard table AUFK.
2. Create a append structure with the Z field ZZLEG_PM_ORD which should be type of BAPIUPDATE and append to the BAPI structure ‘IBAPI_CAUFVD_UPDATE’.
3. Now we should implement the BADI ‘IBAPI_ALM_ORD_MODIFY’ to push the custom field ZZLEG_PM_ORD value to table AUFK. Use the method
IF_EX_IBAPI_ALM_ORD_MODIFY~MODIFY_INPUT_DATA to pass the Z field ZZLEG_PM_ORD value from EXTENSION_IN table to Order header data.
Please use the below logic for updating order header data.
Read the table CT_HEADER_INT into LS_HEADER_INT index 1. Pass the value from EXTENSION_IN-VALUEPART1+0(12) to LS_HEADER_INT-ZZLEG_PM_ORD and modify
the table CT_HEADER_INT.
4. Once we have completed the above steps, while calling the BAPI function module ‘BAPI_ALM_ORDER_MAINTAIN’, we should populate the EXTENSION_IN table and pass
to BAPI as below.
The EXTENSION_IN structure has two fields with name STRUCTURE and VALUEPART1. So pass the STRUCTURE name as
https://blogs.sap.com/2012/08/09/extending-bapi-function-module-bapialmordermaintain/ 1/3
5/15/23, 4:24 PM Extending BAPI Function Module ‘BAPI_ALM_ORDER_MAINTAIN’ | SAP Blogs
RETURN = PT_RETURN
EXTENSION_IN = P_LT_EXTENSION_IN
ET_NUMBERS = LT_ORD_NUM.
Alert Moderator
Assigned Tags
Adding Field in standard Fiori apps of S/4HANA with Custom Fields and Logic
By Masaaki Arai Feb 01, 2020
Related Questions
BAPI_ALM_ORDER_MAINTAIN Zfields Upadate AUFK with BAPI_ALM_ORDER_MAINTAIN
By Maria João Paulo Rocha May 31, 2022 By Krsto Gjergja Aug 01, 2016
6 Comments
Madhu Vadlamani
September 13, 2012 at 7:56 am
Good.Can you explain where you placed these custom fields in the transaction.
Regards,
Madhu.
Like 0 | Share
Vamsi Krishna C V
October 5, 2015 at 3:35 pm
Like 0 | Share
Former Member
October 21, 2012 at 9:13 am
Like 0 | Share
Former Member
December 11, 2012 at 9:37 am
Hi Lakshmi,
Gaurav
Like 0 | Share
https://blogs.sap.com/2012/08/09/extending-bapi-function-module-bapialmordermaintain/ 2/3
5/15/23, 4:24 PM Extending BAPI Function Module ‘BAPI_ALM_ORDER_MAINTAIN’ | SAP Blogs
Former Member
March 22, 2013 at 9:05 pm
Paul
Like 0 | Share
Former Member
November 11, 2013 at 8:17 pm
Lakshmi,
Regards,
Satbir
Like 0 | Share
Find us on
Newsletter Support
https://blogs.sap.com/2012/08/09/extending-bapi-function-module-bapialmordermaintain/ 3/3