Exception block inside trigger?
Ivan Smahin
ivan_smahin at paradigmasoft.com
Tue Sep 25 09:03:08 CDT 2007
Hello Bart,
Tuesday, September 25, 2007, 4:41:15 PM, you wrote:
> Hi List,
> 1) Is it acceptable to have an exception block inside a trigger ?
Hm, need to check but it should be acceptable.
> 2) is this a valid trigger ? More precisely is NEW.recid acceptable
> inside a before insert trigger ?
> CREATE OR REPLACE TRIGGER "trigger_tbl_users_BI" BEFORE INSERT
> ON "tbl_users" FOR EACH ROW
> BEGIN
> if @user_id IS NOT null then
> NEW.objptr_created_by = @user_id;
> NEW.objptr_modified_by = @user_id;
> else
> NEW.objptr_created_by = NEW.recid;-----> ??
> NEW.objptr_modified_by = NEW.recid;---->??
> End IF
> NEW.creation_dt = NOW();
> NEW.modification_dt = NOW();
>
> END;
No, it is not. There is no new record yet.
--
Best regards,
Ivan Smahin
Senior Software Engineer
Paradigma Software, Inc
Valentina - The Ultra-Fast Database
http://www.valentina-db.com
More information about the Valentina
mailing list