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: 

production version in BAPI_SALESORDER_CREATEFROMDAT2

Former Member
0 Kudos

Hi

Is there any parameter to pass the production version in the BAPI.. BAPI_SALESORDER_CREATEFROMDAT2

the thing is there is config settings for auto Production order creation upon sales order creation..till now users creating the sales order manually inturn production order gets created..

Now for automation i tried using the said above BAPI with success.. So is ther any field to pass the prd version?

If not i need to go for BDC:(

appreciate the valuable suggestions..

3 REPLIES 3

Former Member
0 Kudos

AFAIK, production order is created automatically based on the item category settings. Where do your users enter the production version during sales order entry?

0 Kudos

Hi Ken,

Yes, True..Prd Order gets created basing on Item category settings..

but my category got about three versions from to be choosed..

when ever user create sales order with va01 one screen pop up at co01 initial scrren to pick the version among the available versions..

I have the logic to pick the appropriate version basing on certain conditions..

At this point i can write BDC to choose the version..

But my question is is there any parameter in BAPI where we can pass the version number so that that the bapi will take care of passing the version to the CO01?

0 Kudos

As you found out, their is no way to pass production version using the BAPI. But, you could do the following (no specifics but general guidelines):

1) Create a wrapper BAPI (FM) calling the SAP BAPI and add input parameter to accept production version

2) In your wrapper BAPI, export production version to memory and then call SAP BAPI

3) Import production version in appropriate user exit in SAPMV45A (or in an enhancement) and populate the production version there. This will prevent the CO01 popup. You can limit this logic to only when called from the BAPI.

A similar, though not the same, logic works for us during automatic creation of requisitions where we needed to populate the requisitioner.