Full Version: How to find/replace * (an asterisk)
UtterAccess Discussion Forums > Microsoft® Access > Access Queries
Nash
I have a table with a field that has data separated by an *. I can't do an find/replace because when I look search for * it highlights and replaces the entire field. How can I solve this quirk.

Thanks
freakazeud
Hi,
what are you trying to do? Remove the "*", or just find the values which have one in it, or...?
To replace you can try this in an update query:

Replace([YourField],"*","")

To find it use the Instr() Function.
HTH
Good luck
R. Hicks
What as you using ???

Replace([FieldName],"*", "")

The above should remove the asterisk ...

RDH
Nash
It didn't recognize Replace as a function.
R. Hicks
You must not be using it correctly ....

Post "exactly" what you say it does not recognize .. and where you are using it.

RDH
freakazeud
Are you using Acc03 as specified in your version? If yes then replace should work...if it doesn't then maybe you have a reference issue. Open the vba editor (ctrl+g), tools--references...and check if any are marked missing. If yes then correct that. Where did you put the command?
HTH
Good luck
Nash
I created an update query, brought the table in, dropped in the field, and put Replace([FieldName],"*", "") in the Update To line.
R. Hicks
You need to substitute "FieldName" with the actual name of the field that contains the data to alter ...

RDH
Nash
I know, I did that.
R. Hicks
Make sure you have installed all updates for the version of Office/Access you are using.

RDH
Nash
That's strange. I was attempting to do the update query on our server version of Access and it didn't run, but then I exported the table to my hard drive and used the version of Access there - it worked fine. Hmm.

Thanks
R. Hicks
Update Office and Access of the server with all updates and service packs .. and make sure that the latest Jet 4 update has also been installed ...

RDH
Nash
Thanks
R. Hicks
No problem .. wink.gif

RDH
This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please click here.