cancel
Showing results for 
Search instead for 
Did you mean: 

User Exit to Split line iten in VA01

Former Member
0 Kudos

Hi All,

We have a requirement wherein we need to split the line item into 2 and apply a delivery block on the second item if the required quatity exceeds a limit.

We have planned to do this by Custom code through User Exit. Could someone let me know an appropriate Exit for acheiving this funtionality. Please also let me know the tables that need to be manipulated to split the line items.

Note : We are currenlty in SAP 4.6

Regards,

Simin Raveendran.

Accepted Solutions (1)

Accepted Solutions (1)

former_member648947
Active Participant
0 Kudos

Dear Simin,

I have worked on similar requirement before.

Splitting of item is very complex and has impact on all the functionalities in SD.

Please make sure that you have a help from very experienced ABAP consultant and also have a thought process ready for the impact and proposed work arounds ready. Splitting line Item will have impact on Schedule lines, availability , credit management reason for rejections, pricing and so on.

If possible try to see if you have workaround to this requirement alltogether.

in addition to the usersxits mentioned in the earlier reply. you can also use u2022 USEREXIT_SAVE_DOCUMENT_PREPARE in programe MV45AFZZ

I hope this helps to some extent.

Regards,

Paresh

Former Member
0 Kudos

Hi Raga,

Thanks for your reply. I have tried the exits you mentioned but is not working out. I tried this by adding an entry in XKOMV, XVBAP, IVBAP, SVBAP. But still the entry is not appearing in the sales order.

Hi Paresh,

Thanks for your reply. Sorry I didn't mention this earlier. We need the line split to happen before save event. Think the the exit you mentioned is after save event.

Answers (2)

Answers (2)

former_member648947
Active Participant
0 Kudos

Dear Simin,

As i informed you earlier I have worked on similar requirement, and the ABAPer used below mentioned userexit

"USEREXIT_SAVE_DOCUMENT_PREPARE"

Use this user exit to make certain changes or checks immediately before saving a document. It is the last possibility for changing or checking a document before posting.

The user exit is carried out at the beginning of the FORM routine BELEG_SICHERN.

Hope this helps.

Regards,

Paresh

Former Member
0 Kudos

Hi ..

Its not adisable to split the line items into two at the time of Save, this is because when ever a line item is entered in the system, the system performs so many SD functionalities like Pricing, Credit check, Availibility check, Material Determiantion , Incompletion log, Partner functions Etc.... when you do this at the time of save, the system does not perform all the functions, so it might not work as desird. what could be the possible solution for you is..

1) Throw a hard error if a line item exceeds certain qty and give a meaning ful description to the error. so the user who ever entering the order understands this and re enters the item with correct quanity. if you need you can put a delivery block at the time of save .

2) if the order is enterd via EDI or Internet or some legacy. then you can check the logic in the itnerface program and split the item into two before calling the BAPI.

by doing this way you are controling both the manual entered process and automated process.

Former Member
0 Kudos

One Option i could think of -

You can have a BAPI program to run periodically , which will check the order qty of all the Sales Order Line items and then splits accoridng to the logic,( if ord qty > 100 ).

Thanks

Sai

Former Member
0 Kudos

Hi,

MV45AFZZ.

USEREXIT_MOVE_FILED_TO_VBAP,

USEREXIT_MOVE_FILED_TO_VBEP,

Try with above Exits It should WorK.

Thx

RAG