Subject Re: [firebird-support] Re: Using Computed fields in triggers
Author Helen Borrie
At 03:32 AM 14/10/2007, rogervellacott wrote:
>Helen, thanks for your response.
>
>Problem solved I think. The "unreliable" field needed to be excluded
>from the update SQL on a client query.

Not sure.... You should get an exception at Prepare time if your
update statement targets a computed field. If IBO is beneath this
app, it shouldn't even get that far, as a local exception should be
thrown on a non-updatable field before the statement even goes to
prepare. So, if your application code is not using some workaround
to avoid the exception and you can reproduce that condition with a
simple demo, it needs to be reported as a bug in one place or the other.

>The value updated by the trigger was being inadvertently overwritten
>by the client app.

That's a different problem.

>This is not the first time this gotcha has got me.

QA testing? As an IBO user, do you use IB_SQL? Were you aware of
the Query Forms feature in that tool? You can use it to store test
queries for every statement in your application[s] and maintain a
live test bed...

Did you hear what I said about manipulating other tables from Before triggers?

./heLen