07-31-2009 8:07 AM
Hello expterts,
i must develope a programm, which changes characteristics of a batch.
Example:
For material 12345678 we have a batch 9898989898 with class z_batch_class.
This class has serveras characteristics: z_cust_lfsnr
I have to change this charateristic via program. Is there an other possibility than using call transaction MSC2N ?
I am searchin for a FM ode a Bapi.
Can anybody help me?
Thank you
07-31-2009 10:24 AM
HI,
Use the BAPI BAPI_OBJCL_CHANGE.
Pass the OBJECTTABLE as MARA, OBJECTKEY as the complete 18 digit material number, CLASSNUM as the name of the class and CLASSTYPE as the type of the class.
Pass the characteristics values in ALLOCVALUESCHARNEW.
Regards,
Ankur PArab
07-31-2009 10:26 AM
HI,
U can use the below function modules.
1>BAPI_OBJCL_CHANGE
2>BAPI_BATCH_SAVE_REPLICA.
Regards,
Nagaraj
10-16-2009 7:33 PM
Hi Benjamin Pfahl,
I have the same problem, did yo get a function modulo or BAPI to change values characteristics for a especific bach??
Thanks in advance
10-16-2009 8:05 PM
Use this BAPI.
CALL FUNCTION 'BAPI_OBJCL_CHANGE'
EXPORTING
objectkey = w_object
objecttable = 'MCH1'
classnum = itab-classname
classtype = itab-class
TABLES
allocvaluesnumnew = numtab
allocvaluescharnew = chatab
allocvaluescurrnew = curtab
return = rettab.
Let me know if you need more info on this.
~KK
10-17-2009 10:10 PM
Hi,
I think I'm doing something wrong. This is my case:
I have a material (BBBD) with a class (LOTE_GNL_2) with one characteristi (P). I realiced a goods receipt and a batch has been created (0000000060).
What I need to do is modify the characteristis value, "P=aaa" for example.
I pass the next data:
objectkey = 0000000060
objecttable = 'MCH1'
classnum = LOTE_GNL_2
classtype = 023
allocvaluescharnew:
CHARACT=P
VALUE_CHAR=aaa
but I get thew message: "enter a batch".
Could you tell me if I'm doing somethig wrong?
Thanks a lot!!