Consulting

Results 1 to 2 of 2

Thread: converting data

  1. #1

    converting data

    Hi I wonder if anyone can help me with a problem I have with some data. Is it possible to convert numbers in a one field to something else.I have received the data from someone else who uses a different type of data base.
    I have a lot of data that has machines identified as numbers .For example tractor is 1 and all 1sin that field are tractor and 2s are trailers ect.
    I would like to get rid of the numbers and convert them to the machines .I want to be able to do queries on the machines not numbers.
    I hope this makes some kind of sence.

    Thanks for reading this

  2. #2
    VBAX Expert
    Joined
    Oct 2012
    Posts
    726
    Location
    Sounds like normal relational table design.
    Numbers generally take up less space than text, so it's normal to assign numbers to data that is often repeated. The number is called a key. You create one table with unique strings and keys (primary key) and wherever that string is used in other tables you use the number instead of the text (foreign key).

    To replace the numbers with the original string (for display purposes), you join the tables together in queries and replace the number field with the text field.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •