Robert Ogren wrote:
>
> Question:
> This is more than likely a simple one but I am not seeing what would be
> causing this not to work.
>
> create procedure er_raise_error(laerrId int, laerrMsg char(255))
> raise exception laerrId,0,laerrMsg;> 201: A Syntax error occurred ^> end procedure;
>
> In a trigger I call the above Procedure.
> Example:
> execute procedure er_raise_error(-20012,'tblInvDelTrig: Cannot delete
> because foreign keys still exist in tblRacktblInv ')>
> I have permission to create procedures in the DB.
>
> Any help is appreciated.
>
> Thanks
>
> Rob
> rmogren@gte.net
Are you using ISQL to create the SP? If so, don't -- use DB-Access.
ISQL thinks the SP ends at the first semi-colon, which means it sends
a syntactically incorrect statement to the DB. DB-Access knows better.
Yours,
Jonathan Leffler (j.leffler@acm.org) #include <BeenThereDoneThat.h>