Subject | Re: [firebird-support] Is using SELECT COUNT (*) in a stored procedure a bad idea? (Once Again) |
---|---|
Author | Martijn Tonies |
Post date | 2004-01-27T15:06:51Z |
> Q: Is there any way to re-write this stored procedure to quit processingthe
> table after it finds the first occurrence where the ACTIVITY_TYPE_CODE =Actually, I simply do a:
> 'N'?
>
> Q: Is there a better way to trap for FK violations in my interface and not
> use stored procedures at all?
try
.. do delete
except
on E:Exception
do if Pos('FK_<myforeignkeyname>', E.Message) > 0
then ... show message for this particular foreign key and rollback
everything
With regards,
Martijn Tonies
Database Workbench - developer tool for InterBase, Firebird, MySQL & MS SQL
Server.
Upscene Productions
http://www.upscene.com