Parameter | Reference | Type | Length | Default | Optional | Text |
---|---|---|---|---|---|---|
CLIENT | SYST-MANDT | C | 3 | SY-MANDT | X | |
DATE | SYST-DATUM | D | 8 | Currency translation date | ||
FOREIGN_CURRENCY | 0 | Currency key for foreign currency | ||||
LOCAL_AMOUNT | 0 | Amount in local currency | ||||
LOCAL_CURRENCY | 0 | Currency key for local currency | ||||
RATE | 0 | 0 | X | Predefined exchange rate | ||
READ_TCURR | 0 | 'X' | X | Read exchange rate from table TCURR | ||
TYPE_OF_RATE | 0 | 'M' | X | Type of rate M=Average rate G=Bank buying rate B=bank selling rate |
Parameter | Reference | Type | Length | Text |
---|---|---|---|---|
DERIVED_RATE_TYPE | TCURR-KURST | C | 4 | Alternative exchange rate, where used |
EXCHANGE_RATE | 0 | Exchange rate 4.5 | ||
EXCHANGE_RATEX | 0 | Exchange rate 4.11 | ||
FIXED_RATE | 0 | Fixed exchange rate 4.5, if existent | ||
FOREIGN_AMOUNT | 0 | Amount in foreign currency | ||
FOREIGN_FACTOR | 0 | Factor for the foreign currency units | ||
LOCAL_FACTOR | 0 | Factor for the local currency units |
Exception | Text |
---|---|
DERIVED_2_TIMES | Exchange rate type derived more than once |
NO_FACTORS_FOUND | No conversion factors in TCURF |
NO_RATE_FOUND | No exch.rate entered in table TCURR |
NO_SPREAD_FOUND | No spread entered in table TCURS |
OVERFLOW | Field FOREIGN_AMOUNT is too small |
An amount in foreign currency is calculated from a specified localcurrency amount. For this, you may either specify the translation ratemanually (Parameter RATE) or have the system determine it from tableTCURR on the basis of the rate type, date and currency key. Because theratios for the units of the currencies involved in the translation aresignificant for this translation, table TCURR is always read by theprogram, and there must be a valid entry there for the data specified.If exchange rate fixing is defined for exchange rate type TYPE_OF_RATE,or an alternative exchange rate type is defined for the currency pair,this information is transferred to the calling program. When table TCURR is read, the foreign currency key is always taken asthe first part of the key and the local currency as the second part. Ifthis entry is not in the table, the key is re-read in reverse sequence. Sample call-up: CALL FUNCTION 'CONVERT_TO_FOREIGN_CURRENCY' EXPORTING DATE = BKPF-WWERT FOREIGN_CURRENCY = BKPF-WAERS LOCAL_CURRENCY = T001-WAERS LOCAL_AMOUNT = BSEG-DMBTR RATE = BKPF-KURSF TYPE_OF_RATE = 'M' IMPORTING EXCHANGE_RATE = KURS FOREIGN_AMOUNT = BSEG-WRBTR FOREIGN_FACTOR = FAKTOR-F LOCAL_FACTOR = FAKTOR-L EXCEPTIONS NO_RATE_FOUND = 4 NO_FACTORS_FOUND = 8. The exchange rate used for conversion.field.table for the conversion.calculation, an exchange rate can be predefined. Description Value range Default |