The following lines contain the word 'select', 'insert', 'update' or 'delete':
select NVL(AUTHORIZATION_STATUS, 'INCOMPLETE'),
wf_item_type, wf_item_key
into l_authorization_status, x_wf_item_type, x_wf_item_key
from po_requisition_headers_all
where REQUISITION_HEADER_ID = x_object_id;
select NVL(AUTHORIZATION_STATUS, 'INCOMPLETE'),
wf_item_type, wf_item_key
into l_authorization_status, x_wf_item_type, x_wf_item_key
from po_headers_all
where PO_HEADER_ID = x_object_id;
select NVL(AUTHORIZATION_STATUS, 'INCOMPLETE'),
wf_item_type, wf_item_key
into l_authorization_status, x_wf_item_type, x_wf_item_key
from po_releases_all
where PO_RELEASE_ID = x_object_id;
select count(*) into x_count
from po_action_history pah
where
pah.object_id = x_object_id and
pah.object_type_code = x_document_type_code and
pah.object_sub_type_code = x_document_subtype and
pah.action_code is null;
select nvl(podt.can_approver_modify_doc_flag,'N')
into x_can_approver_modify_flag
from po_document_types podt
where
podt.document_type_code = x_document_type_code and
podt.document_subtype = x_document_subtype;
select EMPLOYEE_ID
into x_last_action_emp_id
from po_action_history pah
where
pah.object_id = x_object_id and
pah.object_type_code = x_document_type_code and
pah.object_sub_type_code = x_document_subtype and
pah.action_code is null;
SELECT NVL(MAX(wf.notification_id), -9995),wf.from_role --Bug 12534279
FROM WF_NOTIFICATIONS WF,
WF_ITEM_ACTIVITY_STATUSES WIAS
WHERE WIAS.ITEM_TYPE = x_itemtype AND
WIAS.ITEM_KEY = x_itemkey AND
WIAS.NOTIFICATION_ID = WF.group_id
GROUP BY wf.from_role; --Bug 14205891
SELECT nvl((wfu.orig_system_id), -9996)
FROM wf_users wfu
WHERE wfu.name = p_responder
AND wfu.orig_system not in ('HZ_PARTY', 'POS', 'ENG_LIST', 'CUST_CONT');
SELECT PARAMETER1 AS granter_key
FROM FND_GRANTS g,
fnd_menus m,
fnd_objects o,
fnd_object_instance_sets s
WHERE g.MENU_ID = m.menu_id
AND m.menu_name = 'FND_WF_WORKLIST'
AND g.OBJECT_ID = o.object_id
AND o.obj_name = 'NOTIFICATIONS'
AND g.INSTANCE_SET_ID = s.instance_set_id
AND s.instance_set_name = 'WL_PROXY_ACCESS'
AND g.GRANTEE_KEY = FND_GLOBAL.USER_NAME
AND g.INSTANCE_TYPE = 'SET'
AND g.START_DATE <= SYSDATE
AND Nvl(g.END_DATE, SYSDATE ) >= SYSDATE
UNION
SELECT FND_GLOBAL.USER_NAME AS granter_key
FROM dual;
SELECT wfn.recipient_role, wfn.original_recipient
INTO l_recipient_role, l_original_recipient
FROM wf_notifications wfn
WHERE wfn.notification_id = l_notification_id;