i'd like to insert lots of data n its hard to determine which field would be the primary key, coz all of them almost similar.
So, i decided to use sequence for its PK by using trigger
here's the code :
Create or replace trigger bef_ins_primer
before insert on dpsj_primer
for each row
begin
insert into dpsj_primer values(:new.sto ,:new.rk,:new.a tas,:new.bawah, :new.dmtr,:new. pjng,:new.awal, :new.akhir,:new .kap,:new.isi,: new.ksb,:new.ks r,:new.cad,:new .repsb,:new.wsu cc,:new.tgl_ini t,prim.nextval) ;
end;
Prim is the sequence's name
when i try 2 insert them, here are the error msg
ORA-00036: maximum number of recursive SQL levels (50) exceeded
ORA-06512: at "SYSTEM.BEF_INS _PRIMER", line 2
ORA-04088: error during execution of trigger 'SYSTEM.BEF_INS _PRIMER'
ORA-06512: at "SYSTEM.BEF_INS _PRIMER", line 2
ORA-04088: error during execution of trigger 'SYSTEM.BEF_INS _PRIMER'
ORA-06512: at "SYSTEM.BEF_INS _PRIMER", line 2
ORA-04088: error during execution of trigger 'SYSTEM.BEF_INS _PRIMER'
ORA-06512: at "SYSTEM.BEF_INS _PRIMER", line 2
ORA-04088: error during execution of trigger 'SYSTEM.BEF_INS _PRIMER'
ORA-06512: at "SYSTEM.BEF_INS _PRIMER", line 2
ORA-04088: error during execution of trigger 'SYSTEM.BEF_INS _PRIMER'
ORA-06512: at "SYSTEM.BEF_INS _PRIMER", line 2
ORA-04088: error during execution of trigger 'SYSTEM.BEF_INS _PRIMER'
ORA-06512: at "SYSTEM.BEF_INS _PRIMER", line 2
ORA-04088: error during execution of trigger 'SYSTEM.BEF_INS _PRIMER'
ORA-06512: at "SYSTEM.BEF_INS _PRIMER", line 2
ORA-04088: error during execution of trigger 'SYSTEM.BEF_INS _PRIMER'
ORA-06512: at "SYSTEM.BEF_INS _PRIMER",
Help me plizzz... thx before
So, i decided to use sequence for its PK by using trigger
here's the code :
Create or replace trigger bef_ins_primer
before insert on dpsj_primer
for each row
begin
insert into dpsj_primer values(:new.sto ,:new.rk,:new.a tas,:new.bawah, :new.dmtr,:new. pjng,:new.awal, :new.akhir,:new .kap,:new.isi,: new.ksb,:new.ks r,:new.cad,:new .repsb,:new.wsu cc,:new.tgl_ini t,prim.nextval) ;
end;
Prim is the sequence's name
when i try 2 insert them, here are the error msg
ORA-00036: maximum number of recursive SQL levels (50) exceeded
ORA-06512: at "SYSTEM.BEF_INS _PRIMER", line 2
ORA-04088: error during execution of trigger 'SYSTEM.BEF_INS _PRIMER'
ORA-06512: at "SYSTEM.BEF_INS _PRIMER", line 2
ORA-04088: error during execution of trigger 'SYSTEM.BEF_INS _PRIMER'
ORA-06512: at "SYSTEM.BEF_INS _PRIMER", line 2
ORA-04088: error during execution of trigger 'SYSTEM.BEF_INS _PRIMER'
ORA-06512: at "SYSTEM.BEF_INS _PRIMER", line 2
ORA-04088: error during execution of trigger 'SYSTEM.BEF_INS _PRIMER'
ORA-06512: at "SYSTEM.BEF_INS _PRIMER", line 2
ORA-04088: error during execution of trigger 'SYSTEM.BEF_INS _PRIMER'
ORA-06512: at "SYSTEM.BEF_INS _PRIMER", line 2
ORA-04088: error during execution of trigger 'SYSTEM.BEF_INS _PRIMER'
ORA-06512: at "SYSTEM.BEF_INS _PRIMER", line 2
ORA-04088: error during execution of trigger 'SYSTEM.BEF_INS _PRIMER'
ORA-06512: at "SYSTEM.BEF_INS _PRIMER", line 2
ORA-04088: error during execution of trigger 'SYSTEM.BEF_INS _PRIMER'
ORA-06512: at "SYSTEM.BEF_INS _PRIMER",
Help me plizzz... thx before
Comment