The following lines contain the word 'select', 'insert', 'update' or 'delete':
v_delete_permitted varchar2(1);
select 'Y'
into v_delete_permitted
from sys.dual
where not exists (
select null
from rcv_shipment_headers rcv
where rcv.employee_id = P_PERSON_ID);
select 'Y'
into v_delete_permitted
from sys.dual
where not exists (
select null
from rcv_shipment_lines rcv
where rcv.employee_id = P_PERSON_ID
or rcv.deliver_to_person_id = P_PERSON_ID);
select 'Y'
into v_delete_permitted
from sys.dual
where not exists (
select null
from rcv_transactions rcv
where rcv.employee_id = P_PERSON_ID
or rcv.deliver_to_person_id = P_PERSON_ID)
and not exists (
select null
from rcv_transactions_interface rcv
where rcv.employee_id = P_PERSON_ID
or rcv.deliver_to_person_id = P_PERSON_ID);