The following lines contain the word 'select', 'insert', 'update' or 'delete':
select
form_template_id
,language
,source_lang
,user_template_name
,description
from hr_form_templates_tl
where form_template_id = p_form_template_id
and language = p_language;
select
form_template_id
,language
,source_lang
,user_template_name
,description
from hr_form_templates_tl
where form_template_id = p_form_template_id
and language = p_language
for update nowait;
select tmt.form_template_id
,tmt.user_template_name
,tmt.description
,tmt.source_lang
from hr_form_templates_tl tmt
where tmt.language = userenv('LANG');
delete from hr_form_templates_tl t
where not exists
( select null
from hr_form_templates_b b
where b.form_template_id = t.form_template_id
);
update hr_form_templates_tl t
set ( user_template_name,
description ) =
( select b.user_template_name,
b.description
from hr_form_templates_tl b
where b.form_template_id = t.form_template_id
and b.language = t.source_lang )
where ( t.form_template_id,
t.language
) in
( select subt.form_template_id,
subt.language
from hr_form_templates_tl subb, hr_form_templates_tl subt
where subb.form_template_id = subt.form_template_id
and subb.language = subt.source_lang
and ( subb.user_template_name <> subt.user_template_name
or subb.description <> subt.description
or (subb.description is null and subt.description is not null)
or (subb.description is not null and subt.description is null)
)
);