Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.misc -> Re: Oracle trigger HHHEEELLLPP !
If you ever add a column to your table the trigger will then fail. Are you sure you want to do this???. It is not very good practice. I suggest specifying the column names
Pedro Ramos wrote:
Hello all,Received on Mon Jan 25 1999 - 07:11:56 CSTI have an INSERT trigger on a table that has about 100 columns, when a
row is inserted in the table (TABLEA) I need to insert the same row in
another table (TABLEB).
I don't want to use column names for the insertion, I want to use
something of the kind :INSERT INTO TABLEB SELECT * FROM :NEW
or
INSERT INTO TABLEB SELECT * FROM TABLEA WHERE KEY=:NEW.KEY
But neither of these work, can you give me some help !
Pedro Ramos
PS - The trigger is an after trigger.
I don't want to do something like :INSERT INTO TABLEB (COL1,COL2,COL3,....) VALUES
(:NEW.COL1,:NEW.COL2,:NEW.COL2,...)
![]() |
![]() |