The following lines contain the word 'select', 'insert', 'update' or 'delete':
select element_type_id
from pay_element_types_f
where element_name = p_element_name
and legislation_code = p_legislation_code
and business_group_id IS NULL;
select i.input_value_id
from pay_element_types_f e, pay_input_values_f i
where e.element_name = p_element_name
and i.name = p_input_value_name
and i.element_type_id = e.element_type_id
and i.legislation_code = p_legislation_code
and i.business_group_id IS NULL
and e.legislation_code = p_legislation_code
and e.business_group_id IS NULL;
select db.defined_balance_id
from pay_balance_types b, pay_balance_dimensions d, pay_defined_balances db
where b.balance_name = p_balance_name
and d.dimension_name = p_dimension
and db.balance_type_id = b.balance_type_id
and db.balance_dimension_id = d.balance_dimension_id
and db.legislation_code = p_legislation_code
and db.business_group_id IS NULL
and b.legislation_code = p_legislation_code
and b.business_group_id IS NULL
and d.legislation_code = p_legislation_code
and d.business_group_id IS NULL;
select ABSENCE_ATTENDANCE_TYPE_ID
from per_absence_attendance_types
where name = p_absence_type_name
and business_group_id IS NULL;
select GRADE_ID
from per_grades
where name = p_grade_name
and business_group_id IS NULL;
select global_id
from ff_globals_f
where global_name = p_global_name
and legislation_code = p_legislation_code
and business_group_id IS NULL;
select decode(upper(translate(rtrim(p_PARAMETER_NAME),' ','_'))
,'ABSENCE_TYPE_ID','A'
,'BALANCE_DIMENSION_ID','BD'
,'BALANCE_TYPE_ID','BT'
,'DEFINED_BALANCE_ID','B'
,'ELEMENT_TYPE_ID','E'
,'ID_FLEX_NUMBER','KF'
,'INPUT_VALUE_ID','I'
,'PAYMENT_TYPE_ID','P'
,'USER_ENTITY_ID','UE'
, 'OTHER') Creator_type
from dual;
select element_type_id
from pay_element_types_f
where element_name = p_element_name
and legislation_code = p_legislation_code
and business_group_id IS NULL;
select balance_type_id
from pay_balance_types
where balance_name = p_balance_name
and legislation_code = p_legislation_code
and business_group_id IS NULL;
select balance_dimension_id
from pay_balance_dimensions
where dimension_name = p_dimension_name
and (legislation_code = p_legislation_code or
( legislation_code is null and p_legislation_code is null ))
and business_group_id IS NULL;
select i.input_value_id
from pay_element_types_f e, pay_input_values_f i
where e.element_name = p_element_name
and i.name = p_input_value_name
and i.element_type_id = e.element_type_id
and i.legislation_code = p_legislation_code
and i.business_group_id IS NULL
and e.legislation_code = p_legislation_code
and e.business_group_id IS NULL;
select db.defined_balance_id
from pay_balance_types b, pay_balance_dimensions d, pay_defined_balances db
where b.balance_name = p_balance_name
and d.dimension_name = p_dimension
and db.balance_type_id = b.balance_type_id
and db.balance_dimension_id = d.balance_dimension_id
and db.legislation_code = p_legislation_code
and db.business_group_id IS NULL
and b.legislation_code = p_legislation_code
and b.business_group_id IS NULL
and d.legislation_code = p_legislation_code
and d.business_group_id IS NULL;
select ABSENCE_ATTENDANCE_TYPE_ID
from per_absence_attendance_types
where name = p_absence_type_name
and business_group_id IS NULL;
select GRADE_ID
from per_grades
where name = p_grade_name
and business_group_id IS NULL;
select payment_type_id
from pay_payment_types
where payment_type_name = p_payment_type_name
and (territory_code = p_legislation_code or
( territory_code is null and p_legislation_code is null ));
select user_entity_id
from ff_user_entities
where user_entity_name = p_user_entity_name
and (legislation_code = p_legislation_code or
( legislation_code is null and p_legislation_code is null ))
and business_group_id IS NULL;
SELECT balance_name
FROM pay_balance_types
WHERE balance_type_id = p_balance_type_id;
SELECT balance_type_id
FROM pay_balance_types
WHERE balance_name = p_balance_name
AND legislation_code = p_legislation_code;
SELECT distinct element_name
FROM pay_element_types_f
WHERE element_type_id = p_element_type_id;
SELECT element_type_id
FROM pay_element_types_f
WHERE element_type_id = p_column_value
AND legislation_code = p_legislation_code;
SELECT balance_name
FROM pay_balance_types
WHERE balance_type_id = p_balance_type_id;
SELECT balance_name
FROM pay_balance_types
WHERE balance_name = p_balance_name
AND legislation_code = p_legislation_code;
SELECT distinct element_name
FROM pay_element_types_f
WHERE element_type_id = p_element_type_id;
SELECT element_type_id
FROM pay_element_types_f
WHERE element_type_id = p_column_value
AND legislation_code = p_legislation_code;
SELECT balance_name
FROM pay_balance_types
WHERE balance_type_id = p_balance_type_id;
SELECT balance_name
FROM pay_balance_types
WHERE balance_name = p_balance_name
AND legislation_code = p_legislation_code;
select /*+ ORDERED
INDEX(C FF_USER_ENTITIES_FK1)
INDEX(B FF_DATABASE_ITEMS_FK1)
INDEX(A FF_FDI_USAGES_F_N50) */
distinct a.formula_id
from ff_user_entities c,
ff_database_items b,
ff_fdi_usages_f a
where a.item_name = b.user_name
and a.usage = 'D'
and b.user_entity_id = c.user_entity_id
and c.route_id = p_route_id;
select distinct fdi.formula_id from
ff_fdi_usages_f fdi
,ff_database_items dbi
,ff_user_entities ue
,ff_formulas_f f
where fdi.ITEM_NAME = p_user_name
and fdi.USAGE = 'D'
and ue.USER_ENTITY_ID = dbi.USER_ENTITY_ID
and dbi.USER_NAME = p_user_name
and nvl(ue.legislation_code,'z') = nvl(p_legislation_code,'z')
and f.formula_id = fdi.formula_id
and (( f.legislation_code = p_legislation_code )
or ( f.business_group_id in ( select business_group_id from
per_business_groups bg
where bg.legislation_code = p_legislation_code )));
delete from ff_fdi_usages_f where formula_id = getrec.formula_id;
delete from ff_compiled_info_f where formula_id = getrec.formula_id;
delete from ff_fdi_usages_f where formula_id = getrec.formula_id;
delete from ff_compiled_info_f where formula_id = getrec.formula_id;
delete from ff_fdi_usages_f where formula_id = p_formula_id;
delete from ff_compiled_info_f where formula_id = p_formula_id;