The following lines contain the word 'select', 'insert', 'update' or 'delete':
select opt_typ_cd
from ben_pl_typ_f plt,
ben_pl_typ_opt_typ_f pto
where pto.opt_id = p_opt_id
and plt.pl_typ_id = pto.pl_typ_id
and p_effective_date between plt.effective_start_date
and plt.effective_end_Date
and p_effective_date between pto.effective_start_date
and pto.effective_end_Date ;
select 'x'
from ben_opt_f
where group_opt_id = p_opt_id
and opt_id <> p_opt_id
and effective_end_date > p_effective_date
;
select 'x'
from ben_opt_f
where opt_id = p_group_opt_id
and opt_id = group_opt_id
and p_effective_date between effective_start_date
and effective_end_Date ;
select opt_typ_cd
from ben_pl_typ_opt_typ_f pto ,
ben_pl_typ_f plt
where pto.opt_id = p_opt_id
and plt.pl_typ_id = pto.pl_typ_id
and plt.opt_typ_cd = 'CWB'
and p_effective_date between plt.effective_start_date
and plt.effective_end_Date
and p_effective_date between pto.effective_start_date
and pto.effective_end_Date ;
select null
from ff_formulas_f ff,
per_business_groups pbg
where ff.formula_id = p_rqd_perd_enrt_nenrt_rl
and ff.formula_type_id = -513
and pbg.business_group_id = p_business_group_id
and nvl(ff.business_group_id,p_business_group_id) =
p_business_group_id
and nvl(ff.legislation_code,pbg.legislation_code) =
pbg.legislation_code
and p_effective_date
between ff.effective_start_date
and ff.effective_end_date;
select null
from ben_opt_f
where name = p_name
and business_group_id = p_business_group_id
and opt_id <> nvl(p_opt_id,-1)
and p_validation_start_date <= effective_end_date
and p_validation_end_date >= effective_start_date;
select null
from per_spinal_points spt
where spt.spinal_point_id = p_mapping_table_pk_id
and spt.business_group_id = p_business_group_id;
select null
from ben_opt_f
where mapping_table_name = p_mapping_table_name
and mapping_table_pk_id = p_mapping_table_pk_id
and opt_id <> nvl(p_opt_id,-1)
and p_validation_start_date <= effective_end_date
and p_validation_end_date >= effective_start_date;
Procedure dt_update_validate
(p_cmbn_ptip_opt_id in number default hr_api.g_number,
p_datetrack_mode in varchar2,
p_validation_start_date in date,
p_validation_end_date in date) Is
--
l_proc varchar2(72) := g_package||'dt_update_validate';
End dt_update_validate;
Procedure dt_delete_validate
(p_opt_id in number,
p_datetrack_mode in varchar2,
p_validation_start_date in date,
p_validation_end_date in date,
p_name in varchar2) Is
--
l_proc varchar2(72) := g_package||'dt_delete_validate';
If (p_datetrack_mode = 'DELETE' or
p_datetrack_mode = 'ZAP') then
--
--
-- Ensure the arguments are not null
--
hr_api.mandatory_arg_error
(p_api_name => l_proc,
p_argument => 'validation_start_date',
p_argument_value => p_validation_start_date);
End dt_delete_validate;
Procedure insert_validate
(p_rec in ben_opt_shd.g_rec_type,
p_effective_date in date,
p_datetrack_mode in varchar2,
p_validation_start_date in date,
p_validation_end_date in date) is
--
l_proc varchar2(72) := g_package||'insert_validate';
End insert_validate;
Procedure update_validate
(p_rec in ben_opt_shd.g_rec_type,
p_effective_date in date,
p_datetrack_mode in varchar2,
p_validation_start_date in date,
p_validation_end_date in date) is
--
l_proc varchar2(72) := g_package||'update_validate';
dt_update_validate
(p_cmbn_ptip_opt_id => p_rec.cmbn_ptip_opt_id,
p_datetrack_mode => p_datetrack_mode,
p_validation_start_date => p_validation_start_date,
p_validation_end_date => p_validation_end_date);
End update_validate;
Procedure delete_validate
(p_rec in ben_opt_shd.g_rec_type,
p_effective_date in date,
p_datetrack_mode in varchar2,
p_validation_start_date in date,
p_validation_end_date in date) is
--
l_proc varchar2(72) := g_package||'delete_validate';
SELECT opt.NAME
FROM ben_opt_f opt
WHERE opt.opt_id = p_rec.opt_id
AND p_effective_date BETWEEN opt.effective_start_date
AND opt.effective_end_date;
dt_delete_validate
(p_datetrack_mode => p_datetrack_mode,
p_validation_start_date => p_validation_start_date,
p_validation_end_date => p_validation_end_date,
p_name => l_opt_name,
p_opt_id => p_rec.opt_id);
End delete_validate;
select a.legislation_code
from per_business_groups a,
ben_opt_f b
where b.opt_id = p_opt_id
and a.business_group_id = b.business_group_id;