cancel
Showing results for 
Search instead for 
Did you mean: 

Finance Idoc vs BAPI

steve_coombes
Participant
0 Kudos

Hello,

We have several interfaces in PI that create finance Idocs from files. These have worked well although recently there was a problem and it was suggested that we could use BAPI's, i.e. BAPI_ACC_DOCUMENT_POST,  to create invoice documents as this would allow for the data to be validated.

I thought that I might call BAPI_ACC_DOCUMENT_CHECK first and route message accordingly. If the validation check is successful I would send the message to BAPI_ACC_DOCUMENT_POST, otherwise notify the user who submitted the file.

Does anyone have any comments on which approach we should be using? I appreciate that we will have to decide where data errors should be handled, i.e. by resubmitting a file or by Idocs being edited in ECC, but I am more interested for the moment in the technical implementation details.

I understand that I can create a service interface from a BAPI in PI. However, it looks like the BAPI I mentioned creates one document at a time. Is it possible to use the BAPI to create multiple invoices from one message in PI without separating the initial file into single invoices?

I hope this is the right forum. I wasn't sure whether to post this in a finance group or PI but decided it was slightly more of a PI question.

Kind regards

Steve

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

i would put a wrapper around the bapi and loop the documents in.

then you can call the CHECK and catch and log any errors and send a mail notification with reasons for failure. and then process in successful messages.

steve_coombes
Participant
0 Kudos

Hello Barry

Thanks for your advice.

That seems like a good approach.

Kind regards

Steve

Answers (0)