Link to home
Start Free TrialLog in
Avatar of pauledwardian
pauledwardian

asked on

Access replace comma (,) with dash (-)

This is the access file that I have and I need to replace the commas in ("WorkCodes") column to dashes but I dont know how to do it.
Please help!
Final-Access1.accdb
ASKER CERTIFIED SOLUTION
Avatar of DatabaseMX (Joe Anderson - Former Microsoft Access MVP)
DatabaseMX (Joe Anderson - Former Microsoft Access MVP)
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of pauledwardian
pauledwardian

ASKER

ok this is the querry:
SELECT [SRO Num], DConcat("[Work Code]", "[Table2]", "[SRO Num] = '" & [SRO Num] & "'", ", ", "",
        False, "[Post Date], [Trans Num]" ) AS WorkCodes, Max([Post Date]) AS PostDate
FROM Table2
GROUP BY [SRO Num];

Open in new window

How can I have this querry to create a table after running and then it runs your code for the new created table:
UPDATE Table1 SET Table1.FIELD1 = Replace([FIELD1],",","-");

Open in new window

"How can I have this querry to create a table "

Change it to a MakeTable query ...

But, why not put that expression in the MakeTable query ... and do the conversion all at once ?

mx
Thanks!