Application Development and Automation 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: 
Read only

Using BAPI, BAPI_ACC_GL_POSTING_POST

Former Member
0 Likes
1,124

Hi

I am using this BAPI into a BADI's implementation to post FI document from tcode MIGO.

When running in debug mode, BADI's return table is sucessfull, but whole tcode MIGO short dump, with message:

Short text of error message:

System error in the FI/CO interface

Technical information about the message:

Diagnosis

Updating of the FI/CO interface was called with object type "MKPF" yet the checks were run for object type "BKPFF".

System Response

Checking and updating must be for the same object type.

Can anyone help?

Robert

5 REPLIES 5
Read only

vinod_gunaware2
Active Contributor
0 Likes
870

Hi

try to use

BADI 'ACC_DOCUMENT'

regard

vinod

Read only

Former Member
0 Likes
870

Hi Robert,

This is because it trying to access the material document data before it is getting created. So inside the BADI implementatin dont call BAPI directly. Raise an event which will starts a background job that will do this BAPI call after the material document has been created.

rajkumar

Read only

0 Likes
870

Hi Rajkumar,

I have never raised an event.

Is that mean that I have to create an independant Z program to post the FI document ?

If it's the case, how do I pass the parameters to the program.

Can I create a Z function that will do the post document and call that function from my BADI implementation?

Robert

Read only

0 Likes
870

hi Robert,

1.You can raise an event by calling a FM 'BP_EVENT_RAISE'.

2.Yes you have to create a Z program to post FI document . Form BADI you export the values and in program you import it.

3.No if you call the Z function module also you will get the same error because it is sequential process.

Read only

0 Likes
870

Hi,

I found this way to execute my call function:

CALL FUNCTION 'BAPI_ACC_GL_POSTING_POST' IN BACKGROUND TASK AS SEPARATE UNIT

And it works wery well

Robert