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: 

FM for calculation of FX rate based on reference currency

Former Member
0 Kudos

Dear experts,

I need to carry out currency conversion in a BW transformation. For this, I am using FM CONVERT_TO_LOCAL_CURRENCY which works fine. Some of my exchange rate types use reference currencies, obviously the FM does not support this. Example:

Need to convert:

AUD --> CHF

Rates are maintained for

AUD : EUR

CHF : EUR

and EUR used as reference currency for the FX rate type.

Does anybody know how I can utilize FMs to get the desired result or do I have to calculate it on my own?

Thanks for any suggestions.

BR,

G.

3 REPLIES 3

Former Member
0 Kudos

Hi guys,

found the answer myself: translation ratios have to be maintained for all currency pairs, i.e. also for CHF:AUD.

Thanks for anybody looking at this message.

BR,

G.

SuhaSaha
Advisor
Advisor
0 Kudos

Hello G,

Welcome to SDN !!!

Ideally the table TCURR should have the currency exchange rates for AUD --> CHF. But since you have EUR as a ref for FX rates then you have to use BAPI_EXCHANGERATE_GETDETAIL 2 times.

1. Call BAPI_EXCHANGERATE_GETDETAIL to get FX for AUD ---> EUR, V_RATE1

2. Call BAPI_EXCHANGERATE_GETDETAIL to get FX for CHF ---> EUR, V_RATE2

Now to get the FX rate for AUD --> CHF: V_RATE = V_RATE1 / V_RATE2.

Hope this helps.

BR,

Suhas

Former Member
0 Kudos

Hi Suhas,

I was looking for something exactly like this before I recognized that maintaining the translation ratios will let me use CONVERT_TO_LOCAL_CURENCY and avoid additional development effort. Thanks anyway!

G.