Application Development and Automation 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: 
Read only

Object Classification BAPIs and buffering?

Former Member
0 Likes
970

Hello,

We're using an idoc function module to process multiple changes to Material Classification. We use the following BAPIs to delete, change and create class assignments:

BAPI_OBJCL_DELETE

BAPI_OBJCL_CHANGE

BAPI_OBJCL_CREATE

We only want to commit the data at the end of the process. However, this is now causing us a problem where we delete the classification of one material and then classify another material with the same class & characteristic values for a class with the setting "Check with error" for same classification. Error message C1 818 is raised ('Object "&" already classified with same characteristic values' ).

We feel that BAPI_OBJCL_CREATE should read the data from the buffer and find that the class assignment was already deleted for the first material in the same LUW.

Comments?

Kind Regards,

Markus

3 REPLIES 3
Read only

Former Member
0 Likes
626

Hi Markus,

Did u able to resolve issue which u have mentioned here?

I am also facing same issue.

Thanks

Read only

JackGraus
Active Contributor
0 Likes
626

Hello Markus, I do not have a direct answer to your question but we are using BAPI_OBJCL_CHANGE. The BAPI itself expects the final classification values in the parameter ALLOCVALUES*NEW. In the BAPI itself classification values not available in the input table will be deleted and values that are not yet existing will be created.

Is it possible for you to combine the 3 mentioned BAPI's and just call the *CHANGE* BAPI ?

Regards Jack

Read only

MarkusGrant
Active Participant
0 Likes
626

Hello and thanks for your interest!

As you can see from the date this was quite a few years ago and I have changed company several times since then.

If memory serves me correctly we did the "quick & dirty" solution of committing after the BAPI_OBJCL_DELETE and then performing the BAPI_OBJCL_CHANGE or BAPI_OBJCL_CREATE.

Not an elegant solution but it worked. Hope this helps. As always please check SAP notes to see if anything has changed in this area in the last 4 years!

Kind Regards,

Markus