Pattern matching and substring replacement in PostgreSQL
You haven't disclosed what to do with whitespaces or what to do with overlapping substrings.  Anyhow, something like this could help:

UPDATE tableA
SET field1 = replace(replace(field1, field2, ''), field3, '')
WHERE replace(replace(field1, field2, ''), field3, '') &lt;&gt; '';


There is no pattern to match, simply replace a string (in an other column) with nothing.  You don't have to care about substrings as if the value of field2 does not occur in field1 then it won't be replaced.

See this on SQLFiddle.