The following lines contain the word 'select', 'insert', 'update' or 'delete':
select pbg.security_group_id
from per_business_groups pbg
, pay_org_payment_methods_f opm
where opm.org_payment_method_id = p_org_payment_method_id
and pbg.business_group_id = opm.business_group_id;
select pbg.legislation_code
from per_business_groups pbg
, pay_org_payment_methods_f opm
where opm.org_payment_method_id = p_org_payment_method_id
and pbg.business_group_id = opm.business_group_id;
Procedure chk_non_updateable_args
(p_effective_date in date
,p_rec in pay_opm_shd.g_rec_type
) IS
--
l_proc varchar2(72) := g_package || 'chk_non_updateable_args';
End chk_non_updateable_args;
Procedure dt_update_validate
(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_org_payment_method_id in 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_delete_validate';
If (p_datetrack_mode = hr_api.g_delete or
p_datetrack_mode = hr_api.g_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;
select null
from pay_external_accounts exa
where exa.external_account_id = p_external_account_id
and exists
(select null
from pay_payment_types pty
where pty.payment_type_id = p_payment_type_id
and ((pty.territory_code is not null
and pty.territory_code = exa.territory_code)
or (pty.territory_code is null
and exists
(select null
from per_business_groups pbg
where pbg.business_group_id = p_business_group_id
and pbg.legislation_code = exa.territory_code))));
select count (*)
from pay_org_payment_methods_f pop,
pay_payment_types pyt
where pop.payment_type_id = pyt.payment_type_id
and pyt.category =
( select pyt.category
from pay_payment_types pyt
where pyt.payment_type_id = p_payment_type_id)
and (p_org_payment_method_id is null
or pop.org_payment_method_id <> p_org_payment_method_id )
and pop.external_account_id is not null
and p_effective_date between pop.effective_start_date and pop.effective_end_date
and pop.business_group_id = p_business_group_id;
select null
from fnd_currencies_vl cur
where cur.enabled_flag = 'Y'
and cur.currency_flag = 'Y'
and p_effective_date between nvl(start_date_active,p_effective_date)
and nvl(end_date_active,p_effective_date)
and exists
(select null
from pay_payment_types pty
where pty.payment_type_id = p_payment_type_id
and (pty.currency_code is null
or (pty.currency_code is not null
and pty.currency_code = p_currency_code)));
select null
from pay_payment_types pyt
where pyt.payment_type_id = p_payment_type_id
and ((pyt.territory_code is null)
or exists
(select null
from pay_legislation_rules lgr
where lgr.legislation_code = pyt.territory_code
and lgr.rule_type = 'E'))
and not exists
(select 'x'
from pay_payment_types pyt2,
per_business_groups pbg
where pyt2.category = pyt.category
and pbg.business_group_id = p_business_group_id
and pyt2.territory_code = pbg.legislation_code
and pyt.territory_code is null
and pyt2.payment_type_id <> pyt.payment_type_id);
select db.defined_balance_id
from pay_defined_balances db,
pay_balance_dimensions bd,
pay_balance_types bt
where nvl(db.business_group_id,p_business_group_id) = p_business_group_id
and ((db.legislation_code is null)
or exists
(select null
from per_business_groups pbg
where pbg.business_group_id = p_business_group_id
and pbg.legislation_code = db.legislation_code))
and db.balance_dimension_id = bd.balance_dimension_id
and db.balance_type_id = bt.balance_type_id
and bd.payments_flag = 'Y'
and bt.assignment_remuneration_flag = 'Y'
order by db.business_group_id,db.legislation_code;
select null
from pay_org_payment_methods_f opm
where upper(opm.org_payment_method_name) = upper(p_org_payment_method_name)
and (p_org_payment_method_id is null
or p_org_payment_method_id <> opm.org_payment_method_id)
and opm.business_group_id = p_business_group_id;
select null
from pay_pre_payments ppm
, pay_assignment_actions paa
, pay_payroll_actions ppa
where ppm.org_payment_method_id = p_org_payment_method_id
and ppm.assignment_action_id = paa.assignment_action_id
and paa.payroll_action_id = ppa.payroll_action_id
and ppa.action_type in ('P', 'U')
and ppa.effective_date >= p_validation_start_date;
select lfi.rule_mode
from pay_legislative_field_info lfi
where lfi.validation_type = 'TAB_PAGE_PROPERTY'
and lfi.validation_name = 'DISPLAY'
and lfi.rule_type = 'DISPLAY'
and lfi.field_name = 'COSTING_TAB'
and lfi.target_location = 'PAYWSDPM'
and lfi.legislation_code = l_legislation_code;
procedure chk_delete
(p_org_payment_method_id in pay_org_payment_methods_f.org_payment_method_id%TYPE
,p_business_group_id in pay_org_payment_methods_f.business_group_id%TYPE
,p_datetrack_mode in varchar2
,p_effective_date in date
,p_validation_start_date in date
,p_validation_end_date in date
) is
--
l_proc varchar2(72) := g_package||'chk_delete';
select null
from pay_pre_payments ppt,
pay_assignment_actions paa,
pay_payroll_actions ppa
where ppt.org_payment_method_id = p_org_payment_method_id
and ppt.assignment_action_id = paa.assignment_action_id
and paa.payroll_action_id = ppa.payroll_action_id
and (p_datetrack_mode = hr_api.g_zap
or (p_datetrack_mode = hr_api.g_delete
and p_effective_date < ppa.effective_date));
select null
from pay_org_payment_methods_f_tl opt
where opt.org_payment_method_id = p_org_payment_method_id
and p_datetrack_mode = hr_api.g_zap;
select null
from pay_payroll_actions ppa
where ppa.org_payment_method_id = p_org_payment_method_id
and (p_datetrack_mode = hr_api.g_zap
or (p_datetrack_mode = hr_api.g_delete
and p_effective_date < ppa.effective_date));
select null
from pay_all_payrolls_f ppa
where ppa.default_payment_method_id = p_org_payment_method_id
and ppa.business_group_id = p_business_group_id;
If (p_datetrack_mode = hr_api.g_delete or
p_datetrack_mode = hr_api.g_zap) then
--
-- Ensure the arguments are not null
--
hr_api.mandatory_arg_error
(p_api_name => l_proc
,p_argument => 'effective_date'
,p_argument_value => p_effective_date
);
end chk_delete;
Procedure insert_validate
(p_rec in pay_opm_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 pay_opm_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_datetrack_mode => p_datetrack_mode
,p_validation_start_date => p_validation_start_date
,p_validation_end_date => p_validation_end_date
);
chk_non_updateable_args
(p_effective_date => p_effective_date
,p_rec => p_rec
);
End update_validate;
Procedure delete_validate
(p_rec in pay_opm_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';
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_org_payment_method_id => p_rec.org_payment_method_id
);
pay_opm_bus.chk_delete(p_datetrack_mode => p_datetrack_mode
,p_effective_date => p_effective_date
,p_org_payment_method_id => p_rec.org_payment_method_id
,p_business_group_id => p_rec.business_group_id
,p_validation_start_date => p_validation_start_date
,p_validation_end_date => p_validation_end_date);
End delete_validate;