The following lines contain the word 'select', 'insert', 'update' or 'delete':
g_SelectStmt varchar2(20) := 'SELECT';
g_InsertStmt varchar2(20) := 'INSERT';
g_DeleteStmt varchar2(20) := 'DELETE';
g_UpdateStmt varchar2(20) := 'UPDATE';
select meaning
from fnd_lookups
where lookup_type = 'XDP_PROCEDURE_TYPE'
and lookup_code = code;
select meaning
from fnd_lookups
where lookup_type = 'XDP_OBJECTS'
and lookup_code = code;
select application_mode, display_name
from xdp_adapter_types_vl
where adapter_type = g_AdapterType;
select proc_type
from xdp_proc_body
where proc_name = p_ProcName
and proc_type <> p_ProcType;
if instr(upper(p_ProcBody), 'SELECT ', 1, 1) > 0 then
l_SQLStmt := g_SelectStmt;
if instr(upper(p_ProcBody), 'INSERT ', 1, 1) > 0 then
if l_SQLStmt is null then
l_SQLStmt := g_InsertStmt;
l_SQLStmt := l_SQLStmt || ',' || g_InsertStmt;
if instr(upper(p_ProcBody), 'UPDATE ', 1, 1) > 0 then
if l_SQLStmt is null then
l_SQLStmt := g_UpdateStmt;
l_SQLStmt := l_SQLStmt || ',' || g_UpdateStmt;
if instr(upper(p_ProcBody), 'DELETE ', 1, 1) > 0 then
if l_SQLStmt is null then
l_SQLStmt := g_DeleteStmt;
l_SQLStmt := l_SQLStmt || ',' || g_DeleteStmt;