Results 1 to 7 of 7
  1. #1
    Radtastic10 is offline Advanced Beginner
    Windows 7 64bit Access 2010 64bit
    Join Date
    Feb 2016
    Posts
    65

    Field Parsing question

    I have imported a new table into my DB and it has a field that I want to use in a query. However, the entries in the field are Alpha Numeric values. I am looking for a way to parse the entries to where I can put the number portion into its own field in order to query the information better. The problem I have ran into is that since the entries are just one string of characters there is no delimiters, like a comma or space, for me to use to parse the values.

    Ex. ABC123 ---> I just need to the 123 for the new field.

    But since there are quite a few records in the table I would rather not go entry by entry.



    Thanks

  2. #2
    orange's Avatar
    orange is offline Moderator
    Windows 10 Access 2010 32bit
    Join Date
    Sep 2009
    Location
    Ottawa, Ontario, Canada; West Palm Beach FL
    Posts
    16,847
    You could set up a function to parse the field value. Check each character to see if it is 0-9, if it is put it in the new field. If it is not, skip and check the next character.

    Good luck.

  3. #3
    Radtastic10 is offline Advanced Beginner
    Windows 7 64bit Access 2010 64bit
    Join Date
    Feb 2016
    Posts
    65
    Thanks, I will give it a shot.

  4. #4
    Radtastic10 is offline Advanced Beginner
    Windows 7 64bit Access 2010 64bit
    Join Date
    Feb 2016
    Posts
    65
    I got the parse to work, thanks a lot. But when I tried to do an append query to add the parsed data it just added it to the table but in their own row not to the its corresponding row of data that is already in the table. Was I wrong to use an append query? If so how should I go about getting the parsed data into the correct spots?

  5. #5
    orange's Avatar
    orange is offline Moderator
    Windows 10 Access 2010 32bit
    Join Date
    Sep 2009
    Location
    Ottawa, Ontario, Canada; West Palm Beach FL
    Posts
    16,847
    Sounds like you should be using an update query.

    If this is what you want, then UPDATE query
    Code:
    Record1 yourcurrentField     your newNumericField
                  abcd234mmtwe5    2345

  6. #6
    Radtastic10 is offline Advanced Beginner
    Windows 7 64bit Access 2010 64bit
    Join Date
    Feb 2016
    Posts
    65
    Thanks. Just tried the Update query instead and it worked great.

    I appreciate the help.

  7. #7
    orange's Avatar
    orange is offline Moderator
    Windows 10 Access 2010 32bit
    Join Date
    Sep 2009
    Location
    Ottawa, Ontario, Canada; West Palm Beach FL
    Posts
    16,847
    Happy to help. Good luck with your project.

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

Similar Threads

  1. Parsing field data without delimiters
    By shennin202 in forum Queries
    Replies: 7
    Last Post: 09-13-2013, 05:59 PM
  2. Replies: 6
    Last Post: 06-07-2013, 09:45 AM
  3. Parsing Tilde Delimited Memo Field
    By rmoreno in forum Access
    Replies: 1
    Last Post: 04-22-2013, 04:05 PM
  4. Parsing field into two fields
    By Lewis in forum Queries
    Replies: 5
    Last Post: 11-14-2012, 04:22 PM
  5. Parsing A Comma Delimited Field
    By AccessGeek in forum Import/Export Data
    Replies: 6
    Last Post: 02-03-2011, 01:52 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