Purpose
This article is to explain the standard behavior and trouble shooting suggestion for the Unlimited Flag in service PO.
Standard Behavior of SRM PO :
Create PO manually or from SC
The SRM Service PO item has Unlimited flag = On , not editable.
In BBP_PD , tolerance key CF is filled automatically with Unlimited flag =X.
The field is hard coded in the standard code below:
/SAPSRM/CL_PDO_BO_PO~ADD_ITEM (Add PO Item)
LOOP AT lt_item INTO wa_item . MOVE-CORRESPONDING wa_item TO ls_icu_item. "#EC ENHOK APPEND ls_icu_item TO lt_icu_item. cs_item = ls_icu_item. "When Service is added, the unlimited flag has to be checked in order to create multiple Service Entry Sheet in ERP. "Refer Int Msg: 0120031469 1420950 2011 * When Limit item is added, the unlimited flag has to be checked, this is also for creation of multiple service entry * sheets in ERP * Ref Message: 0120031469 2995736 2011 IF cs_item-product_type = '02' OR cs_item-itm_type = /sapsrm/if_pdo_constants_gen_c=>gc_itm_type_limit. "'LIMI'. CALL FUNCTION 'GUID_CREATE' IMPORTING ev_guid_16 = ls_tol-guid. ls_tol-p_guid = cs_item-guid. ls_tol-unlimited = 'X'. IF cs_item-itm_type = /sapsrm/if_pdo_constants_gen_c=>gc_itm_type_limit."'LIMI'. ls_tol-tol_key = 'CF'. ENDIF. APPEND ls_tol TO lt_tol. CALL METHOD me->/sapsrm/if_pdo_do_tol~add_tolerance EXPORTING it_tol = lt_tol CHANGING co_message_handler = co_message_handler. ENDIF. CLEAR: wa_item, ls_icu_item. ENDLOOP.
Or create from SC :
BBP_PD_PO_CREATE
*For Service items in all scenarios except local, Unlimited flag has to be checked for Tolerance. "When Limit item is added, the unlimited flag has to be checked, this is also for creation of multiple service entry "sheets in ERP "Ref Message: 0120031469 2995736 2011 IF i_header-subtype IS NOT INITIAL. LOOP AT i_item INTO ls_item WHERE product_type EQ '02' OR itm_type = 'LIMI'. CALL FUNCTION 'GUID_CREATE' IMPORTING ev_guid_16 = ls_tol-guid. ls_tol-p_guid = ls_item-guid. ls_tol-unlimited = 'X'. IF ls_item-itm_type = 'LIMI'. ls_tol-tol_key = 'CF'. ENDIF. APPEND ls_tol TO i_tol. CLEAR ls_tol. ENDLOOP. ENDIF.
Standard Behavior When Transfer PO to ECC
- SRM PO is approved and transferred to ECC correctly.
- In the ECC PO service item delivery tab, the Unlimited flag EKPO-UEBTK is set on.
- In the ECC PO service detail of the service tab, the Unlimited flag ESLL-UEBTK is set on.
The reason is, in service PO:
- SRM PO item has only one unlimited flag. It is always auto set on in order to allow multiple service confirmations. Otherwise error M7 022 is issued in ECC during confirmation or service entry.
- MM PO item has 2 unlimited flag:
- 1) Po item delivery tab: Unlimited flag EKPO-UEBTK, This flag should be always set on to allow multiple service confirmations (Service Entry Sheets) for the outline item(EKPO), including all service lines.
- 2) Po item service tab: Unlimited flag ESLL-UEBTK, This flag should be set on to allow multiple service confirmations (Service Entry Sheets) for each single service lines (ESLL).
As MM Purchase order could not be modified in ECS scenario, we map both fields (UEBTK) according to the unlimited flag in SRM PO service item. Otherwise there is no change to set it on in MM process.
This is explained in the code below in the service mapping program LBBP_BD_DRIVER_46AF16.
.
Solution:
If you want to optimize the standard behavior according to your actual business need:
- Implement custom code in BADI: BBP_DOC_CHECK_BADI to check the confirmed quantity in ERP system when confirmation is created in SRM system. (Less affection to standard behavior)
- Implement the BBP_ECS_PO_OUT_BADI , to change the flag mapping during transfer, so that only MM PO unlimited flags are modified.(ECC PO service line ESLL-UEBTK can be optimized)
- Implement the BBP_DOC_CHANGE_BADI, to change the flag in SRM PO during creation ,so that whole PO standard process is are modified.(This is not recommended)
Related SAP Notes/KBAs
2057860 How the unlimited flag in service PO item is mapped to ECC in extended classic scenario
2110690 Incorrect calculation of outstanding quantity for services due to missing Unlim
1911400 No error message pop up when confirmation quantity exceed tolerance for service PO
2148232 Tolerance Flag is not editable for Service PO
1996772 Un limited flag for service item in purchase order
1881416 Unlimited indicator not set for PO's with Service Bundling