‎2009 Jan 13 8:56 AM
Hi all,
I am using function module CONVERT_TO_FOREIGN_CURRENCY for converting INR to USD.
My input data is below
CLIENT 200
DATE 13.01.2009
FOREIGN_CURRENCY USD
LOCAL_AMOUNT 10000
LOCAL_CURRENCY INR
RATE 0
TYPE_OF_RATE M
READ_TCURR XI think data needs to be picked from table TCURR where i have 3 entries for this data
MANDT KURST FCURR TCURR GDATU UKURS FFACT TFACT
200 M INR USD 79918898 48,00000 0 0
200 M INR USD 79919498 50,00000 0 0
200 M INR USD 79989898 47,00000 0 0But the CONVERT_TO_FOREIGN_CURRENCY does not return any value.
BAPI_EXCHANGERATE_GETDETAIL gives the exchange rate details correctly
Any suggestions on how to make this work. Any other settings or table to check ?
Thanks
Edited by: R V on Jan 13, 2009 10:08 AM
‎2009 Jan 13 9:12 AM
‎2009 Jan 13 9:14 AM
Hello RV,
Did you write a code to text this FM? Plz paste the same here.
If you are testing through SE37, plz scroll the screen to the extreme right, you will find the values there. Remember amounts are right justified )
The param READ_TCURR reads exchange rate from table TCURR.
I tried the same with your params & it works for me )
BR,
Suhas
Edited by: Suhas Saha on Jan 13, 2009 10:14 AM
‎2009 Jan 13 9:26 AM
Hi ...if u r trying using se37...
put the date as
DATE : 01132009
and execute..scroll to rt ..ull get output
‎2009 Jan 13 9:31 AM
Hi Saha,
Sorry i did not check properly and directly executed from SE37.
One thing is that EXCHANGE_RATE returns 40.50000 but according to my TCURR tablei don't have this entry.
The latest entry is the first record on 01.11.2008 (48,00000). Why does it pick 40.5 ?
Thanks
‎2009 Jan 13 9:39 AM
can u check the data in TCURR table with
KURST = M
FCURR = USD
TCURR = INR ?
‎2009 Jan 13 9:58 AM
Hi Jolly,
Yes for these details it has 40.5.
Now when i change the input as
CLIENT 200
DATE 13.01.2009
FOREIGN_CURRENCY INR
LOCAL_AMOUNT 10000
LOCAL_CURRENCY USD
RATE 0
TYPE_OF_RATE M
READ_TCURR Xit correctly picks EXCHANGE_RATE = 48.
Can you please explain why ? FOREIGN_CURRENCY is supposed to be USD ?
Thanks
‎2009 Jan 13 10:21 AM
If you read the documentation of the FM, it says.
" When table TCURR is read, the foreign currency key is always taken as
the first part of the key and the local currency as the second part. If
this entry is not in the table, the key is re-read in reverse sequence."
So when you provide data like
CLIENT 200
DATE 13.01.2009
FOREIGN_CURRENCY INR
LOCAL_AMOUNT 10000
LOCAL_CURRENCY USD
RATE 0
TYPE_OF_RATE M
READ_TCURR X
data is read from the table TCURR with FCURR = INR ( Foreign_currency) and TCURR = USD (Local Currency)
Regards,
Aj
‎2009 Jan 13 10:25 AM
Hi Jolly and Saha,
Thank you
Edited by: R V on Jan 13, 2009 11:25 AM
‎2009 Jan 13 9:22 AM
hi
you can try these CONVERT_AMOUNT_TO_CURRENCY
CONVERT_TO_FOREIGN_CURRENCY
CONVERT_TO_LOCAL_CURRENCY
hope this helps
regards
Aakash Banga