Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.server -> Re: Trigger issue

Re: Trigger issue

From: Robert Reimann <robert.reimann_at_gmx.net>
Date: Tue, 10 Aug 1999 10:18:49 +0200
Message-ID: <7oosm7$pf3$1@news.ebn.net>


Try this:

CREATE OR REPLACE TRIGGER test_check

    before
    insert or update on test
    for each row
begin

    if not ((:new.col1 is null and :new.col2 is null and :new.col3 is null)

           or (:new.col1 is not null and :new.col2 is not null and :new.col3 is not null))

      then raise_application_error(-20601,'insert or update not allowed');

    end if;
end; Received on Tue Aug 10 1999 - 03:18:49 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US