Results 1 to 7 of 7
  1. #1
    Kenny84 is offline Novice
    Windows 8 Access 2010 32bit
    Join Date
    Mar 2015
    Posts
    3

    How to update currency exchange rates for multiple records without having to amend each record

    I have a table that lists, amongst others fields, an employees base salary, the currency that is it paid in, the exchange rate to US Dollars and finally the US Equivalent Salary. Being based in Europe, I support various employees across the region who get paid via different currencies, however being a US owned business, all costs get converted into dollars.



    Note: I have a calculation running between the current base salary and the US exchange rate to determine the USD Equivalent Salary.

    I have a field that contains the exchange rates that I plan to update monthly, however with almost 500 employee records, I dont want to have to go through line by line updating them individually.

    Is there a way that I can update the various currencies quickly to avoid this?

    For example:

    Name Job Title Current Base Salary Currency in contract US Exchange Rate USD Equivalent Salary
    Joe Bloggs Manager 80,364.35 British Sterling 1.5438 124,066.48
    Jane Smith Director 90,376.33 Euro 1.119571 106,730.73
    Peter Jones Supervisor 75,934.82 Swiss Franc 1.048256 79,599.13
    Sarah Cole Senior Manager 405,000 Polish Zloty 0.269796 109,267.38


    Next month, when the exchange rates change, the US Exchange Rate values will change which will impact the USD Equivalent Salary.

    I am fairly new to Access so have quite limited knowledge about queries design and macros.

    Thanks
    Last edited by Kenny84; 03-10-2015 at 10:14 AM. Reason: Amendment

  2. #2
    orange's Avatar
    orange is offline Moderator
    Windows XP Access 2003
    Join Date
    Sep 2009
    Location
    Ottawa, Ontario, Canada; West Palm Beach FL
    Posts
    16,870
    You can get exchange rates from https://www.ecb.europa.eu/stats/exch.../index.en.html

    I strongly suggest you work through this tutorial before jumping into your project. An hour spent on the tutorial will help you more than a month or two of trial and error. Learn the concepts of database design before getting too involved with Access or any database software.

  3. #3
    rpeare is offline VIP
    Windows XP Access 2003
    Join Date
    Jul 2011
    Posts
    5,441
    the table you show should be storing a FK (foreign key) to a table with the exchange rates (assuming you have one rate per currency and do not track it over time) and eliminate the US exchange rate field from the table, that would be stored on your newly created exchange rate table

    so for instance your tables would become

    RateID BaseCurrency USRate
    1 British Sterling 1.5438
    2 Euro 1.119571
    3 Swiss Franc 1.048256
    4 Polish Zloty .269796

    EmployeeID EmployeeName CurrentBaseSalary RateID
    1 Joe Bloggs 80364.35 1
    2 Jane Smith 90376.33 2
    3 Peter Jones 75934.82 3
    4 Sarah Cole 405000 4


    Then you only have to update the exchange rate table with the new values and every calculation you do from there will link the RATEID on the employee table to the RATEID on the exchange rate table to figure the US rate.

  4. #4
    Kenny84 is offline Novice
    Windows 8 Access 2010 32bit
    Join Date
    Mar 2015
    Posts
    3
    Thanks rpeare.

    So just to confirm, I do have an seperate underlying table with the exchange rates listed out and then the exchange rate field in the main table uses a lookup so the user can select the appropriate currency for the individual. I think I understand that you are saying to delete the Exchange rate column and just have a calculation linked directly to the underlying table, but then how would you build that so it knows to look at te right currency?

  5. #5
    rpeare is offline VIP
    Windows XP Access 2003
    Join Date
    Jul 2011
    Posts
    5,441
    if you're storing the foreign key to the currency conversion table you can just adopt the description on any form/report/query by linking to the table and including the currency description field from the foreign table.

  6. #6
    Kenny84 is offline Novice
    Windows 8 Access 2010 32bit
    Join Date
    Mar 2015
    Posts
    3
    Sorry im lost.....
    I have now replicated the Currency table you outlined above but Im not sure how to build in a the calculation so that it knows to link the contractual currency, to the underlying table to pull out the exchange rate to multiply their salary into USD equivalent?

  7. #7
    rpeare is offline VIP
    Windows XP Access 2003
    Join Date
    Jul 2011
    Posts
    5,441
    Simple Example

    Kenny84.zip

Please reply to this thread with any new information or opinions.

Similar Threads

  1. Replies: 6
    Last Post: 08-30-2012, 06:23 PM
  2. SQL Update for multiple records
    By robsworld78 in forum Programming
    Replies: 16
    Last Post: 02-26-2012, 09:08 PM
  3. Update Multiple Records
    By anwaar in forum Programming
    Replies: 10
    Last Post: 09-02-2011, 05:16 PM
  4. Update multiple records at once
    By ariklewis in forum Queries
    Replies: 6
    Last Post: 06-13-2011, 02:33 PM
  5. Replies: 1
    Last Post: 12-10-2009, 08:41 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums