Results 1 to 3 of 3
  1. #1
    BDibz is offline Advanced Beginner
    Windows 7 64bit Access 2016
    Join Date
    Feb 2018
    Posts
    62

    "Translate" certain strings


    This seems like such a simple problem, but I can't think of an elegant way to do it.

    I'm trying to salvage a dirty old database and feed its raw data into a new, cleaner one. I need to keep its input fields the same, since new data is regularly appended to it. However, I have a query I am building that pulls the necessary data from it and calculates the needed output fields that I can then use to build my new version of the database.

    The main problem I have right now is that I need to translate old values into new ones; so every time the string "AF2" Is present, it should translate to "Glendale" instead, for example. Is there any simple way to do this?

  2. #2
    CJ_London is offline VIP
    Windows 10 Access 2010 32bit
    Join Date
    Mar 2015
    Posts
    11,933
    create a lookup table with the old value and the new value

    then in your query have a join from the old data to the old value in your lookup table and use instead the new value

  3. #3
    BDibz is offline Advanced Beginner
    Windows 7 64bit Access 2016
    Join Date
    Feb 2018
    Posts
    62
    Quote Originally Posted by Ajax View Post
    create a lookup table with the old value and the new value

    then in your query have a join from the old data to the old value in your lookup table and use instead the new value
    That did it. Thanks.

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

Similar Threads

  1. Replies: 2
    Last Post: 12-23-2015, 09:32 PM
  2. Replies: 1
    Last Post: 09-07-2015, 08:00 AM
  3. Replies: 1
    Last Post: 09-03-2014, 03:27 AM
  4. how to translate "row_number"?
    By mfran2002 in forum Queries
    Replies: 0
    Last Post: 09-17-2008, 03:13 AM

Tags for this Thread

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