Export - Rotex Invoice
Export - Rotex Invoice
Date of supply: Get the value from VBRK – VBELN. pass VBFA – VBELN, VBFA – VBTYP_V as “J”, VBTYP_N
as “M” get VBELV & POSNV.
exchange rate: Pass TCURR – KURST as (M), FCURR as (SAR), TCURR as (USD) and get the UKURS field
value.
Changes: 16.06.2025
Discount: pass VBRK– VBELN get KNUMV, Pass the VBRK - VBELN to VBRP - VBELN and get the POSNR
and pass the KNUMV and POSNR value in PRCD_ELEMENTS - KNUMV, PRCD_ELEMENTS - KPOSN and
PRCD_ELEMENTS – KSCHL value (ZDIS) get KBETR value.
Changes: 16.06.2025
vat category code: pass the value VBRK – VBELN get KNUMV value and pass the KNUMV value into table
PRCD_ELEMENTS – KNUMV and keep the value as KSCHL – ZVS5 For domestic invoice, ZVS6 for export
invoice take MWSK1 value.
Changes on 24.06.2024.
VAT :
Pass VBELN into table VBRK and get the value of field KNUMV.
Pass the value of field KNUMV into PRCD_ELEMENTS Keep KSCHL – ZVS5 (or) ZVS6 for Performa invoice:
F5,F8,ZF5,ZF8 (VBRK - FKART). into table and get the KBETR value for VAT % field and get the KWERT
value for VAT AMOUNT field.
vat exemption reason: Pass VBRK – VBELN get VBRK - KUNRG and pass this value to KNVI – KUNNR and
TATYP as ZVS5 if not there pass ZVS6 and get the TAXKD value and pass the TAXKD and TATYP value into
TSKD – TAXKD and TATYP get VTEXT. If below condition satisfied.
pass the value VBRK – VBELN get KNUMV value and pass the KNUMV value into table PRCD_ELEMENTS –
KNUMV and keep the value as KSCHL not qual to ZVS5, ZVS6
Other Buyer ID: Pass VBRK – VBELN get VBRK – KUNRG and pass the KUNRG Field into DFKKBPTAXNUM –
PARTNER, TAXTYPE as SA1 get TAXNUM value.
buyer and seller already logic present:
end date of supply: pass the value VBRP – VBELN get AUBEL and pass AUBEL value to VBAK – VBELN get
VDATU.
P.O./S.O. Number: pass the value VBRP – VBELN get AUBEL and pass AUBEL value to VBAK – VBELN get
BSTNK & VBELN.
BP - VAT Number: Pass VBRK – VBELN get VBRK – KUNRG and pass the KUNRG Field into
DFKKBPTAXNUM – PARTNER, TAXTYPE as SA0 get TAXNUM value.
Seller - VAT Number : pass VBRK - VBELN get BUKRS next go to T001 table pass BUKRS get STCEG.
vat exemption reason: Pass VBRK – VBELN get VBRK - KUNRG and pass this value to KNVI – KUNNR and
TATYP as ZVS5 if not there pass ZVS6 and get the TAXKD value and pass the TAXKD and TATYP value into
TSKD – TAXKD and TATYP get VTEXT. If below condition satisfied.
pass the value VBRK – VBELN get KNUMV value and pass the KNUMV value into table PRCD_ELEMENTS –
KNUMV and keep the value as KSCHL not qual to ZVS5, ZVS6.
Currency should be document currency i.e SAR and if it is USD - logic(exchange rate: Pass TCURR –
KURST as (M), FCURR as (USD), TCURR as (SAR) and get the UKURS field value.)
Total Taxable Amount(Excluding VAT)(USD) Exchange Rate * Amount (SAR) from line item
Total VAT(SAR) Tax Amount (Tax amount (SAR) from line item)
Invoice Total Amount(Including VAT)(USD) Item Subtotal Including VAT value * Exchange Rate
1. Pass VBELN into table VBRK and get the value of field KNUMV.
Pass the value of field KNUMV into PRCD_ELEMENTS Keep KSCHL – ZVS5 For domestic invoice, ZVS6 for
export invoice into table and get the KBETR value for VAT % field and get the KWERT value for VAT
AMOUNT field.
QTN Logic:
Unit price:
1. Pass VBELN and POSNR into table VBAP and get the value of field KNUMV_ANA.
2. Pass the value of field KNUMV_ANA into KNUMV and POSNR field value from VBAP into KPOSN
and pass KSCHL value as ZPR0 into PRCD_ELEMENTS table and get the KBETR value for Unit
price field and get the KWERT value for AMOUNT field
TAX:
1. Pass VBELN and POSNR into table VBAP and get the value of field KNUMV_ANA.
2. Pass the value of field KNUMV_ANA into KNUMV and POSNR field value from VBAP into KPOSN
and pass KSCHL value as ZVS5 Else ZVS6 into PRCD_ELEMENTS table and get the KBETR value for
VAT % field and get the KWERT value for VAT AMOUNT field.
2. Pass VBELN into table VBRK and get the value of field KNUMV. And
Pass the value of field KNUMV into PRCD_ELEMENTS Keep KSCHL – ZVS5 For domestic invoice, ZVS6 for
export invoice into table and get the KBETR value for VAT % field and get the KWERT value for VAT
AMOUNT field.
VAT :
Pass VBELN into table VBRK and get the value of field KNUMV.
Pass the VBRK - VBELN to VBRP - VBELN and get the POSNR and pass the KNUMV and POSNR value in
PRCD_ELEMENTS - KNUMV, PRCD_ELEMENTS - KPOSN
Pass the value of field KNUMV into PRCD_ELEMENTS Keep KSCHL – ZVS5 (or) ZVS6 for Performa invoice:
F5,F8,ZF5,ZF8 (VBRK - FKART). into table and get the KBETR value for VAT % field and get the KWERT
value for VAT AMOUNT field.