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: 

Table or FM to get Agreement item Tax values

former_member185116
Active Participant
0 Kudos
352

Hello all,

in which table agreement item tax values are stored,

i did not find any records in KONP table, is there any FM to get these values..

5 REPLIES 5

former_member241258
Active Participant
0 Kudos
257

can i know tcode for see above screen in sap

0 Kudos
257

Tcode = ME33K(Display contract agreement)

0 Kudos
257

hi use belo fm

CALCULATE_TAX_ITEM

ex:

CLEAR LS_TAXCOM.
LS_TAXCOM-BUKRS = LS_EKKO-BUKRS.
LS_TAXCOM-BUDAT = LS_EKKO-AEDAT.
LS_TAXCOM-BLDAT = LS_EKKO-BEDAT.
LS_TAXCOM-WAERS = LS_EKKO-WAERS.
LS_TAXCOM-HWAER = LS_EKKO-WAERS.
LS_TAXCOM-KPOSN = LS_EKPO-EBELP.
LS_TAXCOM-MWSKZ = LS_EKPO-MWSKZ.
LS_TAXCOM-WRBTR = LS_EKPO-NETWR.
LS_TAXCOM-XMWST = 'X'.
LS_TAXCOM-SHKZG = 'H'.
LS_TAXCOM-TXJCD = LS_EKPO-TXJCD.
LS_TAXCOM-LIFNR = LS_EKKO-LIFNR.
LS_TAXCOM-EKORG = LS_EKKO-EKORG.
LS_TAXCOM-MATNR = LS_EKPO-MATNR.
LS_TAXCOM-WERKS = LS_EKPO-WERKS.
LS_TAXCOM-MATKL = LS_EKPO-MATKL.
LS_TAXCOM-MEINS = LS_EKPO-MEINS.
LS_TAXCOM-MGLME = LS_EKPO-MENGE.
LS_TAXCOM-MTART = LS_EKPO-MTART.
LS_TAXCOM-LAND1 = LS_EKKO-LANDS.
LS_TAXCOM-EBELN = LS_EKKO-EBELN.
LS_TAXCOM-EBELP = LS_EKPO-EBELP.
LS_TAXCOM-BWTAR = LS_EKPO-BWTAR.



REFRESH:LT_KOMV[].

CALL FUNCTION 'CALCULATE_TAX_ITEM'
EXPORTING
DIALOG = 'DIAKZ'
DISPLAY_ONLY = 'X'
I_TAXCOM = LS_TAXCOM
TABLES
T_XKOMV = LT_KOMV
EXCEPTIONS
MWSKZ_NOT_DEFINED = 1
MWSKZ_NOT_FOUND = 2
MWSKZ_NOT_VALID = 3
STEUERBETRAG_FALSCH = 4
COUNTRY_NOT_FOUND = 5
TXJCD_NOT_VALID = 6
OTHERS = 7.

LOOP AT LT_KOMV INTO LS_KOMV.

CASE LS_KOMV-KVSL1.
WHEN 'JII'.
LS_FINAL-IGST = LS_FINAL-IGST + ( ( LS_KOMV-KBETR / 1000 ) * LS_RSEG-WRBTR ).
WHEN 'JIC'.
LS_FINAL-CGST = LS_FINAL-CGST + ( ( LS_KOMV-KBETR / 1000 ) * LS_RSEG-WRBTR ).
WHEN 'JIS'.
LS_FINAL-SGST = LS_FINAL-SGST + ( ( LS_KOMV-KBETR / 1000 ) * LS_RSEG-WRBTR ).
WHEN 'JIM'.
LS_FINAL-IMGST = LS_FINAL-IMGST + ( ( LS_KOMV-KBETR / 1000 ) * LS_RSEG-WRBTR ).
ENDCASE.

ENDLOOP.

0 Kudos
257

hi use belo fm

CALCULATE_TAX_ITEM

ex:

CLEAR LS_TAXCOM.
LS_TAXCOM-BUKRS = LS_EKKO-BUKRS.
LS_TAXCOM-BUDAT = LS_EKKO-AEDAT.
LS_TAXCOM-BLDAT = LS_EKKO-BEDAT.
LS_TAXCOM-WAERS = LS_EKKO-WAERS.
LS_TAXCOM-HWAER = LS_EKKO-WAERS.
LS_TAXCOM-KPOSN = LS_EKPO-EBELP.
LS_TAXCOM-MWSKZ = LS_EKPO-MWSKZ.
LS_TAXCOM-WRBTR = LS_EKPO-NETWR.
LS_TAXCOM-XMWST = 'X'.
LS_TAXCOM-SHKZG = 'H'.
LS_TAXCOM-TXJCD = LS_EKPO-TXJCD.
LS_TAXCOM-LIFNR = LS_EKKO-LIFNR.
LS_TAXCOM-EKORG = LS_EKKO-EKORG.
LS_TAXCOM-MATNR = LS_EKPO-MATNR.
LS_TAXCOM-WERKS = LS_EKPO-WERKS.
LS_TAXCOM-MATKL = LS_EKPO-MATKL.
LS_TAXCOM-MEINS = LS_EKPO-MEINS.
LS_TAXCOM-MGLME = LS_EKPO-MENGE.
LS_TAXCOM-MTART = LS_EKPO-MTART.
LS_TAXCOM-LAND1 = LS_EKKO-LANDS.
LS_TAXCOM-EBELN = LS_EKKO-EBELN.
LS_TAXCOM-EBELP = LS_EKPO-EBELP.
LS_TAXCOM-BWTAR = LS_EKPO-BWTAR.



REFRESH:LT_KOMV[].

CALL FUNCTION 'CALCULATE_TAX_ITEM'
EXPORTING
DIALOG = 'DIAKZ'
DISPLAY_ONLY = 'X'
I_TAXCOM = LS_TAXCOM
TABLES
T_XKOMV = LT_KOMV
EXCEPTIONS
MWSKZ_NOT_DEFINED = 1
MWSKZ_NOT_FOUND = 2
MWSKZ_NOT_VALID = 3
STEUERBETRAG_FALSCH = 4
COUNTRY_NOT_FOUND = 5
TXJCD_NOT_VALID = 6
OTHERS = 7.

LOOP AT LT_KOMV INTO LS_KOMV.

CASE LS_KOMV-KVSL1.
WHEN 'JII'.
LS_FINAL-IGST = LS_FINAL-IGST + ( ( LS_KOMV-KBETR / 1000 ) * LS_RSEG-WRBTR ).
WHEN 'JIC'.
LS_FINAL-CGST = LS_FINAL-CGST + ( ( LS_KOMV-KBETR / 1000 ) * LS_RSEG-WRBTR ).
WHEN 'JIS'.
LS_FINAL-SGST = LS_FINAL-SGST + ( ( LS_KOMV-KBETR / 1000 ) * LS_RSEG-WRBTR ).
WHEN 'JIM'.
LS_FINAL-IMGST = LS_FINAL-IMGST + ( ( LS_KOMV-KBETR / 1000 ) * LS_RSEG-WRBTR ).
ENDCASE.

ENDLOOP.

0 Kudos
257

or if not work

use tables : bkpf and bseg.