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

userexit - bapi

Former Member
0 Likes
723

Hi Guys:

How we can find out userexits of the BAPI function module

<b>Example:</b> I would like to do modification on the following BAPI Fun.module <b>BAPI_ACC_GL_POSTING_POST</b>

Thanks in Advance

Suresh Babu Karanam

6 REPLIES 6
Read only

Former Member
0 Likes
669

Hi in the SE37 you can make a copy of the BAPI and named:

ZBAPI_ACC_GL_POSTING_POST

then you may edit all you want!

Don't forget the FG, i recommend you to make a copy Z1031 (FG for the BAPI BAPI_ACC_GL_POSTING_POST) and use it with the ZBAPI_ACC_GL_POSTING_POST.

Read only

Former Member
0 Likes
669

Hi Carlos Lerzundy:

my requirement is as soon as document Created by using <b>BAPI_ACC_GL_POSTING_POST </b> Fun. Module i need to update <b>document type and Ztable</b> since it was mapped with <b>XI for FI postings</b>.

If any one have idea how to find userexits of BAPI plz lemme know.

Advanced Thanks

Suresh Babu Karanam

Read only

0 Likes
669

Hi Suresh,

Possible solutions:

1. Use User-Exit ACBAPI01 (see trans SMOD) which is called in FM BAPI_ACC_GL_POSTING_POST. You have to implement this UE in your own project (trans CMOD). Update your Z-table but do not do a "commit work" inside your CMOD-project. Check the return parameters from the BAPI call. If OK, then do a normal "commit work" for your Z-table update and a call to FM BAPI_TRANSACTION_COMMIT for the BAPI commit.

2. Create a "wrapper" FM that calls the BAPI first. If OK, then update Z-tables. Commit as in case 1.

IMHO, there is no need to copy this FM or the function group.

Hope this helps,

//Johan

Read only

0 Likes
669

Hi Suresh,

The suggestions given by Johan seem to be the best alternatives (though I have not verified the user-exit he mentioned). I don't think copying the BAPI with its function group is a good idea.

All the best,

Regards,

Anand Mandalika.

Read only

Former Member
0 Likes
669

Thanks Johan and Anand:

I have found a Customer Exit in BAPI itself it contains zinclude (<b>EXIT_SAPLACC4_001 and ZXACCU15</b>) so probebly i can use that.

Regards

Suresh Babu Karanam

Read only

0 Likes
669

Hi Suresh

The User-Exit ACBAPI01 that I mentioned above is indeed called from the BAPI. Have a look at the coding as I assume you also have done. That was they way I found the UE as well.

I would go for this solution first of all because this is the most "SAP"-ish way to do it because you are using a SAP defined UE. No changes or modifications. Do an implemntation in CMOD and set a break-point first of all. Then run the trans and inspect the "incoming" data structures. From my undestanding you will have a reference to structure ACCIT where you have BELNR, GJAHR and BUZEI among other fields. These should help to get unique references in your Z-table.

And as a help for all others, please mark this question as solved if apropriate.

<i>And as a last thing, let me introduce you the SDN forums pointing system: You can assign points to posts you find helpful while solving your question. You can reward points by clicking the yellow star icon at header of each reply post. You can reward;

- one 10 points (solved)

- two 6 points (very helpful answer)

- many 2 points (helpful answer)</i>

Regards, Johan