while inserting a record thru form, it gives me the following error: FRM-40508-ORACLE ERROR UNABLE TO INSERT RECORD. (All fields are having data).
I am using a PRE-INSERT trigger at form level. At time of inserting a new record the following records which are "not null" are to be inserted. PRR_RD_RQ_SN is the primary key which is inserted by taking the max.
Where should I use the PRE-insert trigger - at form level or block level.
When I execute the following trigger in PL/SQL, it doesn't give any error.
Where am I making a mistake ????
PRE-INSERT Trigger----
Declare
t_prr_rd_rq_sn number(15);
BEGIN
Select max(ilclp.t_opr_prr.prr_rd_rq_sn)+1 into t_prr_rd_rq_sn from ILCLP.T_OPR_PRR ;
Insert into ILCLP.T_OPR_PRR
(prr_rd_rq_sn, prr_tt_n_be_rd, prr_tt_b_be_rd, prr_tt_s_be_rd, prr_rlm_ur_u, prr_rlm_ts, prr_rlm_tp,
prr_sno, prr_ms_sn, prr_tt_p_be_rd, prr_pe_sn_bnf, prr_aw_cd_u, prr_xm_og_ty_no, prr_xm_og_ty_no_m, prr_xm_og_ty_no_ff, prr_sh_mhd_ty_no )
Values (t_prr_rd_rq_sn, 1, 1, 1,sys_context('userenv','current_user'),
sysdate, sys_context('userenv','ip_address'),1, 1, 1, 1,'011', 10, 10, 10, 10 );
END;
---------------------
Thankx
Raj
I am using a PRE-INSERT trigger at form level. At time of inserting a new record the following records which are "not null" are to be inserted. PRR_RD_RQ_SN is the primary key which is inserted by taking the max.
Where should I use the PRE-insert trigger - at form level or block level.
When I execute the following trigger in PL/SQL, it doesn't give any error.
Where am I making a mistake ????
PRE-INSERT Trigger----
Declare
t_prr_rd_rq_sn number(15);
BEGIN
Select max(ilclp.t_opr_prr.prr_rd_rq_sn)+1 into t_prr_rd_rq_sn from ILCLP.T_OPR_PRR ;
Insert into ILCLP.T_OPR_PRR
(prr_rd_rq_sn, prr_tt_n_be_rd, prr_tt_b_be_rd, prr_tt_s_be_rd, prr_rlm_ur_u, prr_rlm_ts, prr_rlm_tp,
prr_sno, prr_ms_sn, prr_tt_p_be_rd, prr_pe_sn_bnf, prr_aw_cd_u, prr_xm_og_ty_no, prr_xm_og_ty_no_m, prr_xm_og_ty_no_ff, prr_sh_mhd_ty_no )
Values (t_prr_rd_rq_sn, 1, 1, 1,sys_context('userenv','current_user'),
sysdate, sys_context('userenv','ip_address'),1, 1, 1, 1,'011', 10, 10, 10, 10 );
END;
---------------------
Thankx
Raj