Subject Re: [firebird-support] Replacing substrings...
Author Paul Vinkenoog
Sergio H. Gonzalez wrote:

>> update changeme set field01 = replace(field01, 'Fpdd', '<newvalue>')

> ...and if the table has a lot of records, probably adding
>
> where position ('Fpdd' in field01)> 0
>
> would help... or it's the same, regarding performance?

Performance would be the same or slightly worsse, I think. All records have to be scanned anyway; if you add the WHERE clause, the contents of matching records will be scanned twice: once by POSITION, and then once by REPLACE.


Paul Vinkenoog