cancel
Showing results for 
Search instead for 
Did you mean: 

How to assign Batch for GR materials( 101 mvt type) while using BAPI_PRODORDCONF_CREATE_TT

buttisandeep
Explorer
0 Kudos

Hi Experts,

         At CO11N, system is providing Automatically Batch for Material with Mvt type 101.

       Now a third party system is sending Production Order (AUFNR) and YIELD. 

    I'm using BAPI_PRODORDCONF_CREATE_TT for Production confirmation. System is doing 261 mvt type(GI) but not GR (101 mvt type) . I can see the error in COGI as "ENTER BATCH"

Need guidance in this regard. 

buttisandeep_0-1711555364664.png

 

Thanks & regards

Sandeep

Accepted Solutions (0)

Answers (2)

Answers (2)

arjuna_bandara
Participant
0 Kudos

Hi,

You can also try to generate a new batch number using BAPI_BATCH_CREATE with parameters material and plant (where order to be created) and pass the generated batch number as an import parameter to BAPI_PRODORDCONF_CREATE_TT.

buttisandeep
Explorer
0 Kudos
Hi Arjuna,
buttisandeep
Explorer
0 Kudos
Hi Arjuna, Here the Batch is generated used customized code. We have used the same code to fill the batch field. At present the problem being faced is : I have used BAPI_PRODORDCONF_GET_TT_PROP to get 101 and 261 mvt type proposals. I have given yield in timetickets and expected 101 and 261 quantities will be in accordance with yield qty, But system is proposing 101 and 261 as per balance production order qunatities. For Ex: I have provided yield as 1 in time tickets and system is proposing quantity 2 Nos as balance order qty is 2 Nos.
Caetano
Product and Topic Expert
Product and Topic Expert
0 Kudos

Hello

You can use BAPI_PRODORDCONF_GET_TT_PROP to get the default values for order confirmation, change according to your needs, and use as an input to BAPI_PRODORDCONF_CREATE_TT, as suggested in the following thread:

https://community.sap.com/t5/enterprise-resource-planning-q-a/entering-an-external-batch-number-via-...

Regards,
Caetano