Subject | Re: [firebird-support] Re: Very Slow Update Query |
---|---|
Author | gordon@gniessen.com |
Post date | 2011-05-25T14:24:24Z |
Quoting Jack Mills <millsjack14@...>:
<SNIP>
I am not sure from your thread if you are only having an issue with
this one update. Or if you have a problem with all updates on this
database and this is just a simple example.
If it is just this update, how about if you do the following instead:
update disc set area_code = ltrim(area_code) WHERE AREA_CODE < '0';
and get a return of PLAN (DISC INDEX (DISC_IDX1))
You could also add the LTRIM to the Trigger and only have to do the
update once.
Then the performance would not be an issue.
<SNIP>
> The update statement is "update disc set area_code = ltrim(area_code)"<SNIP>
> The returned Plan "PLAN (DISC NATURAL)"
>
I am not sure from your thread if you are only having an issue with
this one update. Or if you have a problem with all updates on this
database and this is just a simple example.
If it is just this update, how about if you do the following instead:
update disc set area_code = ltrim(area_code) WHERE AREA_CODE < '0';
and get a return of PLAN (DISC INDEX (DISC_IDX1))
You could also add the LTRIM to the Trigger and only have to do the
update once.
Then the performance would not be an issue.