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

Home -> Community -> Usenet -> c.d.o.misc -> Trigger Question - Error

Trigger Question - Error

From: John Bringolf <jbringolf_at_uncfsu.campus.mci.net>
Date: 1997/03/04
Message-ID: <331CAB13.789E@uncfsu.campus.mci.net>#1/1

I keep getting an error on the following trigger - any suggestions:

create or replace trigger check_attach
before update of attachment on TABLE1 FOR EACH ROW declare
  Invalid_Entry EXCEPTION;
  test varchar2(4);
begin
  select SOMETHING into test
    from Z.PERS WHERE SSAN = :old.ssan;
  if (     :new.attachment IS NOT NULL
     AND   :new.attachment = test      ) THEN
     RAISE Invalid_Entry;

  END IF;
  EXCEPTION
    WHEN Invalid_Entry THEN
     RAISE_APPLICATION_ERROR (-20001,'Test'); end;

ERROR at line 1:

ORA-20001: Test
ORA-06512: at line 13
ORA-04088: error during execution of trigger 'MED.CHECK_MED_ATTACH'

Thanks JB Received on Tue Mar 04 1997 - 00:00:00 CST

Original text of this message

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