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

Close PR's

Former Member
0 Likes
667

Hi All,

I have a requirement where i need to create a report to close all PR's that were created a year ago. Please note that i need to Close them and not delete them.

FOr this i have come upon two BAPI's

1 BAPI_PR_CHANGE

2 BAPI_REQUISITION_DELETE

Please let me know so as to which one will serve my purpose,and what are the fields that should be changed for this purpose .

It would be GR8 if some1 has a sample code for the same.

Thanks in Advance

5 REPLIES 5
Read only

kesavadas_thekkillath
Active Contributor
0 Likes
632

Use BAPI_REQUISITION_DELETE.

Please read the documentation.

Read only

Former Member
0 Likes
632

Both will work

Please check the links below

Please if you need further info check in the forum with the bapi names

Regards

Satish Boguda

Read only

Former Member
0 Likes
632

To Keshav.T,

Hi Keshav thanks for the info, i have one more query

How can i get the error report from the BAPI??

ie I need to print out which all PR's were closed successfully and the ones that were not closed with the reason for not closing ,

Please help.....

Im rewarding u points for the first answer!11

Read only

0 Likes
632

The bapi will be having a retrun table which stores the messages.

You can refer this link[http://wiki.sdn.sap.com/wiki/display/Snippets/BAPIReturnMessage+Capturing]

Read only

Former Member
0 Likes
632

used BAPI_PR_CHANGE and BDC to solve the issue