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

BApi

Former Member
0 Likes
1,112

Hello friends,

How does Bapi work. I mean whne I create a Sales order using a BAPI does it check for the data That I am passing. WOuld it look if The material exist, would it do for the combination of sales area, or do I need to check it explicitly.

Shejal.

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
605

Hi,

BAPI usually will perform input data check.

You may not necessary to perform data validation prior to call the BAPI. If any input data error occured, the BAPI will raise an exception.

Also please add this BAPI BAPI_TRANSACTION_COMMIT at the end for commit work purposes.

Regards,

Ferry Lianto

6 REPLIES 6
Read only

Former Member
0 Likes
606

Hi,

BAPI usually will perform input data check.

You may not necessary to perform data validation prior to call the BAPI. If any input data error occured, the BAPI will raise an exception.

Also please add this BAPI BAPI_TRANSACTION_COMMIT at the end for commit work purposes.

Regards,

Ferry Lianto

Read only

Former Member
0 Likes
605

It does checks the validity of the material and the combination and so on. Only if the data you are passing to the BAPI exists in the system it creates the order. Otherwise throws a system message like the same when you populate the data to a transaction.

Read only

0 Likes
605

Thanks Ferry and Vinni.

DOes anyone have some real time example using,

BAPI_PLANNEDORDER_CREATE.

Shejal.

Read only

Former Member
0 Likes
605

Hi,

Sorry I don't have any sample codes.

But perhaps you can check module pool MDBAPI01 or transaction MDBA.

Also check this link perhaps it may help (not in English)

http://sap4.com/funcion-274.html

Regards,

Ferry Lianto

Read only

0 Likes
605

Thanks Ferry,

The sample program helps. I am assuming that is all have to be done for creating a planned order.

However i have a text file and it comes to my Internal table in the program and I am assuming I have to pass the data of the internal table in to the export parameters of the FM.

Thanks again for the sample report..

Shejal.

Read only

0 Likes
605

Sorry, I don't have one either but I can assist you if you need any help on it while you are coding.

yes, you are right. Hope everything goes smooth.