03-15-2010 3:45 AM
Hello Experts ,
I am currently using BAPI_BATCH_SAVE_REPLICA to create batch with characteristics . I have a requirement to fill characteristic name and value . The field names of the same are ATNAM and ATWRT respectively. The firld name of characteristic description is ATBEZ. Going through certain threads of SDN I have understood I need to pass values to CLASSALLOCATIONS and CLASSVALUATIONSCHAR . Inspite of doing the same I able to create a batch but without characteristics. I am posting here the values i passed please tell how to resolve this issue.
For CLASSALLOCATIONS
CLASS_TYPE 022
STATUS 1
CLASSNUM RM_LIFE_BATCH
For CLASSVALUATIONSCHAR
CLASS_TYPE 022
CHARACT TACK_LIFE
VALUE_CHAR 200
CHARACT_DESCR TACK LIFE
-Thanks
Trishna
03-15-2010 5:08 AM
03-15-2010 5:08 AM
03-17-2010 3:30 AM
Hey Andrey!
Thanks alot! Now i can see the characteristic. But , there is a slight problem while i have passed only one characteristic , it is still picking up other characteristics which are unassigned. Also , the value for given characteristic was not updated through BAPI. Please tell how to go ahead.
03-17-2010 4:25 AM
09-01-2010 8:29 AM
Hi Trishna,
I am facing similar issue to update classification value using BAPI: BAPI_BATCH_SAVE_REPLICA. But unable to update the same, Please can u send me your code, or what are the mandatory values need to pass in classification tables in BAPI.
Please find my code. and help me where I need to correct.
WA_BATCHCONTROLFIELDS-DOCLASSIFY = 'X'.
WA_CLASSALLOCATIONS-CLASS_TYPE = '023'.
WA_CLASSALLOCATIONS-STATUS = '1'.
WA_CLASSALLOCATIONS-CLASSNUM = 'BATCH_CLASS_RM'.
APPEND WA_CLASSALLOCATIONS TO I_CLASSALLOCATIONS.
WA_CLASSVALUATIONSCHAR-CLASS_TYPE = '023'.
WA_CLASSVALUATIONSCHAR-CHARACT = 'VOLUME'.
WA_CLASSVALUATIONSCHAR-VALUE_CHAR = '90.10'.
WA_CLASSVALUATIONSCHAR-CHARACT_DESCR = 'VOLUME'.
APPEND WA_CLASSVALUATIONSCHAR TO I_CLASSVALUATIONSCHAR.
wa_batchatt-expirydate = '20200909'.
wa_batchattx-expirydate = 'X'.
wa_batchstatus-restricted = ' '.
wa_batchstatusx-restricted = 'X'.
l_matnr = '3401031500200'.
l_charg = 'ABC0000003'.
l_werks = 'X100'.
CALL FUNCTION 'BAPI_BATCH_SAVE_REPLICA'
EXPORTING
material = l_matnr
batch = l_charg
plant = l_werks
batchattributes = wa_batchatt
batchattributesx = wa_batchattx
batchstatus = wa_batchstatus
batchstatusx = wa_batchstatusx
BATCHCONTROLFIELDS = WA_BATCHCONTROLFIELDS
TABLES
return = i_batch_ret
CLASSALLOCATIONS = I_CLASSALLOCATIONS
CLASSVALUATIONSCHAR = I_CLASSVALUATIONSCHAR.
CALL FUNCTION 'BAPI_TRANSACTION_COMMIT'.
Thanks,
Shreekant
10-29-2010 2:21 PM
Hi Shreekant,
In addition to the data you pass, below fields
OBJECTKEY = concatenate 'Internal Material number' & plant & batch number
OBJECTTABLE = MCHA
in bothe the structures CLASSALLOCATIONS and CLASSVALUATIONSCHAR. It will udpate.
Cheers,
Luri
01-24-2014 7:48 AM
Hi,
Can I use this FM to create batch with classification and If yes how can I do it?
Cheers,
Lechoo