‎2006 Jul 25 4:37 PM
Hi,
My problem is this:
I have to compare manually entered serial numbers in the delivery to the serial numbers entered in the Sales Order. Now, this must be done on saving the document, so, I figured I would put some code to do the check in userexit_save_document in program MV50AFZ1, but my problem is, I cannot find out how to read what serial numbers are currently in the delivery in that userexit. Does anyone know if they are stored in an internal table, in a buffer, or what?
Any help would be greatly appreciated.
Andrew
‎2006 Jul 25 4:51 PM
Hi Andrew,
Please check this tables.
<b>SER01</b> - Document Header for Serial Numbers for Delivery
<b>SER02</b> - Document Header for Serial Nos for Maint.Contract (SD Order)
Hope this will help.
Regarsd,
Ferry Lianto
Please reward points if helpful.
‎2006 Jul 25 4:51 PM
Hi Andrew,
Please check this tables.
<b>SER01</b> - Document Header for Serial Numbers for Delivery
<b>SER02</b> - Document Header for Serial Nos for Maint.Contract (SD Order)
Hope this will help.
Regarsd,
Ferry Lianto
Please reward points if helpful.
‎2006 Jul 25 5:03 PM
I think at the point of that user exit, the serial numbers are not yet in the database.
See if internal table GT_SERNO_CHANGE is available and populated in the user exit.
EDIT:
Just checked. That internal table only FLAGS that were changed.
‎2006 Jul 25 5:53 PM
Hi,
Yeah, SER01 is for deliveries, but it is not populated until the deilvery is saved . . . so there must be some kind of internale table there that has the information, but I still have not been able to find it . . .
For GT_SERNO_CHANGE, as you said, it is a flag.
I too am still searching . . .
‎2009 May 12 4:23 PM
FM GET_SERNOS_OF_DOCUMENT will return the serial numbers in the delivery. I called it from form USEREXIT_SAVE_DOCUMENT. The input parameter "key_data" takes structure RSEROB which contains the table for serial numbers (TASER = 'SER01'), the delivery number (LIEF_NR), and the item number (POSNR).
Edit: This method doesn't return the serial numbers until the delivery has been saved; i.e. if the delivery is saved first then posted later this works.