Subject Re: [firebird-support] Silent exception / rollback
Author Martijn Tonies
Hi,

> Is it possible not to permit database action ( like deleting,
> updating) based on SP result w/o exception message ? For example ,
> I would like to stop deleting a record if stored procedure
> called by trigger "before delete" returns me "False" , and I don't
> want to see any messages !!! .
>
> Don't be focused on deleting , because based on this I would like to
> implement that based on one field value I can stop someone to change
> another field.

This would only be possible if you raise an exception in the
trigger and "eat" that exception on the client side.

Another possibility would be to revoke any DELETE rights
from the table except for a procedure that you call and let
it check for that exception and eat it instead of doing a DELETE
FROM statement yourself.

With regards,

Martijn Tonies
Database Workbench - developer tool for InterBase, Firebird, MySQL & MS SQL
Server.
Upscene Productions
http://www.upscene.com