Results 1 to 4 of 4
  1. #1
    JKaranka is offline Novice
    Windows XP Access 2002
    Join Date
    Jun 2011
    Posts
    2

    Replace hash (#) with query

    Hi guys!

    I have been having this problem with trying to replace hashes from a field for a little while. I know that they are wildcards for number in queries, but still, the usual brackets approach doesn't seem to help when within a replace function.

    The two main failed attempts have been run an update query in which the field is updated to the following:

    a) Replace([Age],Chr(35),"")
    b) Replace([Age],"[#]","")

    Neither one of which has replaced any hashes.

    Any help would be appreciated!

  2. #2
    jzwp11 is offline VIP
    Windows 7 64bit Access 2010 64bit
    Join Date
    Jun 2010
    Location
    Dayton, OH
    Posts
    2,901
    Can you post the SQL text of the query you wrote? I tried the following in an example database and it worked with no problems

    UPDATE Table1 SET Table1.myTextField = Replace(mytextfield,"#"," ");

  3. #3
    JKaranka is offline Novice
    Windows XP Access 2002
    Join Date
    Jun 2011
    Posts
    2
    Hah, you are completely right. I cannot believe I have been trying to square the circle nor I understand how I ended up trying to! Thanks!

  4. #4
    jzwp11 is offline VIP
    Windows 7 64bit Access 2010 64bit
    Join Date
    Jun 2010
    Location
    Dayton, OH
    Posts
    2,901
    You're welcome!

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

Similar Threads

  1. Replies: 6
    Last Post: 07-25-2012, 06:42 AM
  2. auto replace??
    By d3pl0y3d in forum Access
    Replies: 2
    Last Post: 02-11-2011, 02:09 PM
  3. Find and Replace query from a 2nd table
    By elightbox in forum Queries
    Replies: 1
    Last Post: 09-17-2010, 05:37 PM
  4. Create Hash - Copy File to string
    By andrew_ww in forum Programming
    Replies: 0
    Last Post: 03-20-2010, 02:14 AM
  5. Find and Replace Query
    By randolphoralph in forum Queries
    Replies: 4
    Last Post: 03-17-2010, 07:25 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