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

Creating PO using BAPI

Former Member
0 Likes
802

I want to create a PO using BAPI...

Can nebdy give me a sample program as to how to do it...

How to use BAPI_PO_CREATE1 ??? What are the basic parameters needed to create a PO using it .

Please help !!!

4 REPLIES 4
Read only

Former Member
0 Likes
625

Hi,

plz check the following thread........

/people/sap.user72/blog/2005/03/22/sample-code-to-create-purchase-order-using-bapi-in-r3

***do reward if usefull

vijay

Read only

Former Member
0 Likes
625

Hi!

The followings are required (in most cases)

- POHEADER

- POITEM

- POSCHEDULE

With these you are able to create a new PO.

Just fill all those field, you fill manually in ME21N.

Regards

Tamá

Read only

Former Member
0 Likes
625

Look at excellent weblog to create PO

/people/sap.user72/blog/2005/03/22/sample-code-to-create-purchase-order-using-bapi-in-r3

Thanks

Seshu

Read only

0 Likes
625

You can use the following :

CALL FUNCTION 'BAPI_PO_CREATE'

EXPORTING

PO_HEADER = PO_HEAD

IMPORTING

PURCHASEORDER = H_EBELN

TABLES

PO_ITEMS = PO_ITEM

PO_ITEM_SCHEDULES = PO_SCHED

PO_ITEM_ACCOUNT_ASSIGNMENT = PO_ACCT

PO_ITEM_TEXT = PO_TEXT

EXPORTING

PO_HEADER = PO_HEAD

IMPORTING

PURCHASEORDER = H_EBELN

TABLES

PO_ITEMS = PO_ITEM

PO_ITEM_SCHEDULES = PO_SCHED

PO_ITEM_ACCOUNT_ASSIGNMENT = PO_ACCT

PO_ITEM_TEXT = PO_TEXT

After this u can use 'BAPI_TRANSACTION_COMMIT'

Thanks,

Rakesh.