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: 

Characteristics in Batch (CHARG)

Former Member
0 Kudos

Hi, i need a bapi to create characteristics to an already created CHARG by the BAPI_BATCH_CREATE

Regards

ttorres

1 ACCEPTED SOLUTION

Former Member
0 Kudos

BAPI_BATCH_CREATE can be used to Create the classification of a batch in the background.

Excerpt from the BAPIs documenation: If the batch is to be classified, you must specify a class in the BatchControlFields parameter. Only single classification is possible.

If you need a different BAPI, Use BAPI_OBJCL_CREATE to create characteristics.

-Kiran

13 REPLIES 13

Former Member
0 Kudos

BAPI_BATCH_CREATE can be used to Create the classification of a batch in the background.

Excerpt from the BAPIs documenation: If the batch is to be classified, you must specify a class in the BatchControlFields parameter. Only single classification is possible.

If you need a different BAPI, Use BAPI_OBJCL_CREATE to create characteristics.

-Kiran

0 Kudos

ok, tks let me try it

ttorres

0 Kudos

Hi Kiran,

I am uploading the characteristics in batch.I am getting a problem that what i need to pas to the import parameter OBJECTKEYNEW.It is a 50 character length.

If i send only material number then it shows the error enter a batch.

If i pass material,batch and plant concatenated then it shows the error

Material does not exists.Please help me if you have done.

Its very urgent.

0 Kudos
The Object Key is a string of 27 characters.  It is the combination of first the material number and then the batch number with the difference between the 27 character length being added as spaces between the two values.
I'm not a SAP programmer, really, but having to integrate with SAP had me encountering this same error on BAPI_OBJCL_GETDETAIL.  The documentation on these BAPI parameters is limited and I had to step through the German to figure this out - here is what getting the Object Key looks like in C#: 

string OBJECT_ID = MAT_NUM + Strings.Space(27 - (MAT_NUM.Length + BATCH_NUM.Length)) + BATCH_NUM;

---------------------------------------------------

sprechen sie deutsch?

Former Member
0 Kudos

Hi,

Try using BAPI_CHARACT_CREATE to create the characteristics for the batch that has been already created with BAPI_BATCH_CREATE,

Rgds,

Former Member
0 Kudos

Hi, none of the bapis solve my problem, and it's my fault, what i need it to add values to an already created characteristic

0 Kudos

Use BAPI_CHARACT_CHANGE.

Lookup documentation in BAPI for 'how to use'.

0 Kudos

Hey,

You could use BAPI_OBJCL_CHANGE to update classification data of batches.

For batches the object table is MCHA and the class type is 023.

-Kiran

*Please reward useful answers

Former Member
0 Kudos

Hi, thanks for your help, it's solved. I've used BAPI_BACTH_CREATE for the CHARG and BAPI_OBJCL_CHANGE and BAPI_OBJCL_CREATE for the characteristics values. Be carefull with the objectkey parameter it's a little bit tricky

ttorres

0 Kudos

Please reward points and close the thread if your query is resolved.

Thanks, Kiran

0 Kudos

Hi Torres,

What is supposed to be passed in the objectkey parameter? I'm passing the batch id there. But seems it's not correct. Can you please help?

Thanks,

Dipankar

0 Kudos

- sorry .. replied for mistake

Edited by: Gabriele Montori on Mar 2, 2011 9:43 AM

0 Kudos

Hi Torres,

what parameter should be pass to objectkey?

I also have same problem..please reply its urgent.

Thanks