Advertisement
If you have a new account but are having problems posting or verifying your account, please email us on hello@boards.ie for help. Thanks :)
Hello all! Please ensure that you are posting a new thread or question in the appropriate forum. The Feedback forum is overwhelmed with questions that are having to be moved elsewhere. If you need help to verify your account contact hello@boards.ie
Hi there,
There is an issue with role permissions that is being worked on at the moment.
If you are having trouble with access or permissions on regional forums please post here to get access: https://www.boards.ie/discussion/2058365403/you-do-not-have-permission-for-that#latest

currency logic

  • 18-05-2017 9:39pm
    #1
    Registered Users, Registered Users 2 Posts: 859 ✭✭✭


    I know this is a simple maths question but if I get it wrong it could be expensive.

    I have a system that stores current exchange rates. The base currency is USD so everything is stored as 1 USD = x.xxx A N Other currency.

    The request from the business is to fix a subset of the rates against the EUR

    e.g. 1 EUR must always equal 1.9557 BGN

    We get fresh daily rates via a webservice (Third party).

    So I'm multiplying the USD:EUR rate by the fixed rate (BGN) rate and storing this as the USD BGN rate

    e.g. 1 USD = 0.9 EUR today means 1 USD = 0.9 * 1.9557 BGN
    -- the USD:BGN rate moves with the EUR

    Am I doing this right?


Comments

  • Registered Users, Registered Users 2 Posts: 785 ✭✭✭ILikeBananas


    Well if the Euro floats relative to the US $ but is fixed versus the BGN then by that logic yes the BGN should also float relative to the US $.

    In this example the Bulgarian Lev has been pegged to the Euro as part of the process of them eventually adopting the Euro currency (We had the same experience with our punt being fixed versus the Euro from 1999-2002).

    So 1 Euro = 1.9557 BGN and
    1 US$ = 0.9 Euro.

    Therefore 1 Euro = 1/0.9 US $ = 1.1111 US$

    and thus, 1.9557 BGN = 1.1111 US$
    1 US$ = 1.9557 / 1.1111 = 1.7601 BGN

    So, yes I think you're doing it right.


  • Registered Users, Registered Users 2 Posts: 1,722 ✭✭✭rock22




Advertisement