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: 

Update LIKP not working

Former Member
0 Kudos

Hi,

I am trying to updating LIKP table but its not happening. If the same test data is executed twice the update happens correctly a second time.

I tried using commit work and wait but even then its not happening.

12 REPLIES 12

Former Member
0 Kudos

Hi

I am not sure, why you are updatig LIKP directly.

This is not a good practice and also SAP will not support for the same.

Pls check, whether any enhancements or user exits available.

In case you want to update during delivery creation.

you can use USEREXIT_MOVE_FIELD_TO_LIKP.

Regards

Madhan

0 Kudos

Hi madhan,

I have to update the LIKP-BEROT field at the time of picking..So, after picking is done this location has to be updated.

Can you suggest a alternative?

0 Kudos

Hi

I beleive when you do picking, even the deliver program (SAPMV50A) is triggered.

Try to code in USEREXIT_MOVE_FIELD_TO_LIKP.

When you to update while saving means.

You can try

USEREXIT_SAVE_DOCUMENT_PREPARE.

Modify XLIKP internal table

You can try the above in debug mode, keep the break-points at above User exit sub routines and try to change in debug mode and see whether it works.

Regards

Madhan

Former Member
0 Kudos

Hi,

By Update you will be changing the existing record right ?

If you are trying to upload new records it is not the right command. I think you need to wait for some time and check after you execute it for the first time.

Regards,

Pramod

0 Kudos

I am doing Commit work and wait. Even thats not working. And yes I am updating existing record.

0 Kudos

Check sy-subrc after updating.

0 Kudos

Sy-subrc is zero. I am checking that before doing commit.

0 Kudos

Then the key fields in the where condition did change. How does your update statement look like?

0 Kudos

This is how i am doing it -

UPDATE likp SET aenam = update_by berot = berot WHERE vbeln = delivery.

IF sy-subrc = 0 .

COMMIT WORK AND WAIT.

endif.

0 Kudos

This is how i am doing it -

UPDATE likp SET aenam = update_by berot = berot WHERE vbeln = delivery.

IF sy-subrc = 0 .

COMMIT WORK AND WAIT.

endif.

0 Kudos

This is how i am doing it -

UPDATE likp SET aenam = update_by berot = berot WHERE vbeln = delivery.

IF sy-subrc = 0 .

COMMIT WORK AND WAIT.

endif.

0 Kudos

Check if delivery still contains the expected value.