‎2007 Jul 08 9:03 AM
need to write the code for this routine please help me
 Routine will check if plant in Delivery for which billing document is being created exists in specific table (TVARV) for plants equal to bonded warehouse.
 If record existing in the table, proceed further else exit from program and create single billing document.
 If plant exists in specific/customized table,
o Check: delivery existing in the table J_1IRG23D.
o If record not existing, display error message Excise Invoice/BOE not selected for delivery document and exit from the program without creating the billing document.
o If record existing in table J_1IRG23D, Extract VBELN, STATUS, EXNUM, EXYEAR, DEPEXNUM, DEPEXYEAR from table J_1IRG23D for VBELN = delivery and STATUS = P.
o Sort data on field EXNUM, EXYEAR
o Filter the unique records based on EXNUM & EXYEAR.
 Split the billing document based on unique EXNUM & EXYEAR.
‎2007 Jul 08 10:27 AM
Hi Bijender,
Welcome to SDN :).
You should first try to write code on your own, and if you stuck somewhere then we can help you.
Regards,
Atish
‎2007 Jul 08 10:49 AM
*{ INSERT DRAK906812 1
----
FORM DATEN_KOPIEREN_602 *
----
---> VBAK Order Header KUAGV View Sold-to *
VBAP Order item KURGV View Payer *
VBKD Business data order KUREV View Bill-to *
LIKP Delivery Header KUWEV View Ship-to *
LIPS Delivery item *
----
************************************************************************
*} INSERT
FORM DATEN_KOPIEREN_602.
*{ INSERT DRAK906812 1
IF SY-UNAME = 'EBP7478'.
Header data
VBRK-xxxxx = ............
Item data
VBRP-xxxxx = ............
Additional split criteria
DATA: BEGIN OF ZUK,
MODUL(3) VALUE '001',
VTWEG LIKE VBAK-VTWEG,
SPART LIKE VBAK-SPART,
ABTNR LIKE LIPS-ABTNR,
EMPST LIKE LIPS-EMPST,
END OF ZUK.
ZUK-SPART = VBAK-SPART.
ZUK-VTWEG = VBAK-VTWEG.
ZUK-ABTNR = LIPS-ABTNR.
ZUK-EMPST = LIPS-EMPST.
VBRK-ZUKRI = ZUK.
**********************************
A D D I T I O N A L C O D E *
**********************************
here i need the code to written
ENDIF.
*} INSERT
ENDFORM.
‎2007 Jul 08 10:59 AM
Hi Bijender,
Yes I got your requirement.
But you should write the code. If there is any error or issue then we can help you.
Regards,
Atish
‎2007 Jul 08 11:16 AM
i am not able to understand the logic if i would have understand the logic i could have written that please help me to make me understand the logic so that i can start wirtting the code .