Enterprise Resource Planning Blogs by Members
Gain new perspectives and knowledge about enterprise resource planning in blog posts from community members. Share your own comments and ERP insights today!
Showing results for 
Search instead for 
Did you mean: 

Hello everyone!! In this blog, I am going to explain how the next due date of Maintenance plan can be updated with the implementation of BADI "BADI_EAM_EXIT_IPRM002".

What is Usage Decision:  

In QM, Usage Decision is used to decide whether you want to accept or reject the goods in the inspection lot based on the result of the inspection. As per inspection results the process is marked as completed in T-code QA32.


When we perform the calibration activity using Inspection lot once after performing Usage decision(UD) for the inspection lot the next due date against the Maintenance plan is not updating the table MHIO "Bas. start date (GSTRP)" field instantly.

Bas.start Date is not updated when UD was done 01.02.2022

The due date will be updated only on the next day when background job runs or when the user manually go to t-code IP10 and save the Maintenance plan.

Due date got updated as 01.02.2022 when user executed IP10


Business need was to automate this process without changing the frequency of background job which executes the API "MPLAN_UPDATE_SCHEDULING" and also by avoiding the  manual execution in IP10 transaction.

Solution Approach:

In our custom program logic which performs the Usage Decision of Maintenance Plan, we have made a call to the API "MPLAN_UPDATE_SCHEDULING" to update the MHIO table.

After above code changes the MHIO table got updated correctly

API execution in the custom program updated Bas.start date in MHIO table as 01.02

Issues faced:

  1. MHIS table was not updated with the new date and also wrong dates were visible in IP03 t-code because the FM "MPLAN_UPDATE_SCHEDULING" updates date only after order is set in TECO status.

To avoid this, found and implemented the below BADI "EXIT_SAPLIPM5_002"

BADI to update Next Due date

2. As we change only MMDD in the above BADI, we faced another problem when different Calibration cycles used i.e., MON, DAY, YR.

Updated Custom logic for UD, to avoid problem for different Calibration cycles used.


After implementing the BADI and code changes in our custom program, we were able to achieve the requirement which updates the Due date correctly.

MHIO GSTRP updated as UD date

MHIS Planned date updated as UD date

IP03 Plan date also updated as UD date


I hope this blog will be helpful for technical consultants who has a similar requirement of updating Plan Due date in Maintenance plan after Usage Decision is saved in QA32 transaction.

Please share your valuable feedback and thoughts in the comments section.

For related topics please follow the below link and read other posts on the topic:



Please follow my profile for related information. Thanks Everyone 🙂
Labels in this area