Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

Posting key in BAPI_ACC_DOCUMENT_POST

Former Member
0 Kudos

Hi All,

when i am using BAPI_ACC_DOCUMENT_POST.

it executes successfully but

if i enter the amount with + sign it uses 01 as the posting key.

if i entered the amount with - sign it selects 11 as posting key.

but requirement is instead of 11 I want 50 as posting key.

how it determines the key?

and can i change the posting key?

How can I pass the posting key field to this BAPI?

Thanks and regards,

Sri Lakshmi.

2 REPLIES 2

Former Member

Former Member
0 Kudos

Hi

The choise of posting key (by BAPI BAPI_ACC_DOCUMENT_POST) depends on the kind of item and the sign of amount.

A) If the item is for customer:

01 if amount > 0

11 if amount < 0

B) If the item is for vendor:

21 if amount > 0

31 if amount < 0

C) If the item is for g/l account:

40 if amount > 0

50 if amount < 0

So if you're obtaining the posting key 11 instead of 50, it means u're transfering item for customer instead of g/l account.

Max