I'm doing some pre-processing on an input file. From my Delphi app, I want to issue a command like the following to my MS Access db:

update importfile set realfirst = replace(realfirst, ',', '') where (instr(realfirst, ',') > 0)

If open a query in the db and execute that statement, it works.

If I put that statement in an ADOQuery's SQL or a KADAOTable's SQL and try to ExecSQL on it, Delphi gives me an "undefined function 'replace' in expression" error.

I've used both the D5 ADO query using an MS JET 4.0 connection, and with a DAO query. It fails the same way in both.