Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.server -> Re: Trigger issue
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