Results 1 to 5 of 5
  1. #1
    alinapotter is offline Novice
    Windows 7 64bit Access 2010 32bit
    Join Date
    Apr 2013
    Posts
    11

    update query that removes extra letters

    I need to create an update query that removes the extra letters xxx and ggg from the field in my table. I am having a trouble finding a right function that goes to "update to" field. I need help. I am taking an access class and got stuck on this step of my assignment.

  2. #2
    June7's Avatar
    June7 is offline VIP
    Windows XP Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    52,931
    You want to remove 3 x's and 3 g's that are in sequence?

    Try:

    Replace(Replace([fieldname],"xxx",""),"ggg",""))
    How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.

  3. #3
    alinapotter is offline Novice
    Windows 7 64bit Access 2010 32bit
    Join Date
    Apr 2013
    Posts
    11
    Yes, there are 3 x's and g's in the begining or middle of the words. I just need to remove them so those words look normal. For example, Nevada and not xxxNevada or Texas and not Tegggxas.

  4. #4
    June7's Avatar
    June7 is offline VIP
    Windows XP Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    52,931
    Did you try suggestion? Make copy of the table for testing before running on the real data because can't undo.

    No situations like Hagggard where the 2 g's are correct?
    How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.

  5. #5
    alinapotter is offline Novice
    Windows 7 64bit Access 2010 32bit
    Join Date
    Apr 2013
    Posts
    11
    It worked! Thank you.

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

Similar Threads

  1. Have a Query only look at the last 4 letters in a name
    By matthewmessmer in forum Queries
    Replies: 3
    Last Post: 02-11-2013, 12:42 PM
  2. Replies: 3
    Last Post: 11-22-2012, 08:01 PM
  3. Query. Extra column.
    By seweryng in forum Queries
    Replies: 1
    Last Post: 01-14-2011, 08:59 AM
  4. Adding table to Query removes every 4th record
    By CoachBarker in forum Queries
    Replies: 1
    Last Post: 10-13-2010, 07:23 AM
  5. Extra date field update
    By georgft in forum Forms
    Replies: 0
    Last Post: 09-17-2008, 06:51 AM

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