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: 

BAPI that shows if a PO is rejected?

Former Member
0 Kudos
500

Is there any standard bapi that will tell me if a PO has been rejected via ME29N?

Cheers

Greg

1 ACCEPTED SOLUTION

manthanraja
Active Participant
265

BAPI_ACC_PURCHASE_ORDER_CHECK Accounting: Check Purchase Order

BAPI_PO_GETDETAIL Display Purchase Order Details

BAPI_PO_GETITEMSREL List Purchase Orders for Release (Approval): New as of 4.0A

BAPI_PO_GETRELINFO Display Detailed Release (Approval) Information on Purchase Order

Did you try any of these ???

Regards

Manthan.

8 REPLIES 8

manthanraja
Active Participant
266

BAPI_ACC_PURCHASE_ORDER_CHECK Accounting: Check Purchase Order

BAPI_PO_GETDETAIL Display Purchase Order Details

BAPI_PO_GETITEMSREL List Purchase Orders for Release (Approval): New as of 4.0A

BAPI_PO_GETRELINFO Display Detailed Release (Approval) Information on Purchase Order

Did you try any of these ???

Regards

Manthan.

kesavadas_thekkillath
Active Contributor
0 Kudos
265

Did you check BAPI_PO_GETDETAIL, parameter PO_HEADER , field status

Former Member
0 Kudos
265

I tried looking at BAPI_PO_GETDETAIL, BAPI_PO_GETITEMSREL and BAPI_PO_GETRELINFO but the status does not change if I reject the PO. Interestingly BAPI_PO_GETITEMSREL still returns the PO as an item available to be rejected!

Any other options?

0 Kudos
265

Did you use Explicit Commit after you used the Bapi .. ?

BAPI_PO_GET_DETAIL is your best bet .. did you check using it .. it has a field which is in focus HIstory

Also did you try the solution by Keshav ?

BR

Manthan.

0 Kudos
265

I did check BAPI_PO_GETDETAILS and BAPI_PO_GETDETAILS but the status does not change and their is no history record.

I know the PO's I am looking at have definitely been rejected via ME29N.

Any other options?

Cheers

Greg

0 Kudos
265

Check the status in EKKO after rejecting via ME29N

0 Kudos
265

You are correct in that BAPI_PO_GETITEMSREL returns rejected PO's. When a PO is rejected EKKO- PROCSTAT eq 08. So your best bet would be to write a custom BAPI with the addtional selection criteria of EKKO-PROCSTAT ne 08. This is what we have to do.

anup_deshmukh4
Active Contributor
0 Kudos
265

will FRGKE field in EKKO Release Indicator: Purchasing Document will help you ..!