BAPI_REQUISITION_CREATE Create purchase requisition

When the account assignment category is M

If the account automatic posting is configured, REQUISITION_ACCOUNT_ASSIGNMENT passes the sales order number, the account number cannot be passed, if it is passed, an error will be reported: ME038 "For general ledger accounts, no direct accounting can be done in the company code". It is correct that the subject number is not transmitted, but if BAPI cannot find the subject automatically, an error will be reported: 06138 "It is impossible to determine a consumption account"

Specific cause:

ME51N will find the account automatically posted according to the entered sales order with KZBWS =''. The function SD_ORDER_CHECK cannot be found. The function has an enhancement. Calling the function SD_DOCUMENT_ACCOUNT_ASSIGNMENT in the enhancement will change E_COBL-KZBWS to'A', and then go check.

The function for checking accounts is ME_ACCOUNT_ASSIGNMENT.

BAPI will only directly check according to KZBWS =''. If the subject configuration is not standard at this time (Table T030), BAPI will appear BUG,

At this time, make an implicit enhancement. At the beginning of the function ME_ACCOUNT_ASSIGNMENT, limit TCODE and change I_KZBWS to'A'

 

 

Guess you like

Origin blog.csdn.net/cylcylcylcylwo/article/details/114015116