The following lines contain the word 'select', 'insert', 'update' or 'delete':
select bg.business_group_id,
bg.name,
sp.security_profile_id,
sp.security_profile_name
from per_security_profiles sp,
per_business_groups bg
where sp.security_profile_id = nvl(p_sp_id,sp.security_profile_id)
and sp.business_group_id = nvl(p_bg_id,sp.business_group_id)
and sp.business_group_id = bg.business_group_id
and sp.view_all_flag = decode(bg.business_group_id,null,
sp.view_all_flag,'Y') ;
select V.PROFILE_OPTION_VALUE
from FND_PROFILE_OPTIONS O, FND_PROFILE_OPTION_VALUES V
where O.PROFILE_OPTION_NAME = option_name
and V.LEVEL_ID = 10003 and V.LEVEL_VALUE = to_char(resp_id)
and V.LEVEL_VALUE_APPLICATION_ID = to_char(appl_id)
and O.PROFILE_OPTION_ID = V.PROFILE_OPTION_ID
and O.APPLICATION_ID = V.APPLICATION_ID ;
select V.PROFILE_OPTION_VALUE
from FND_PROFILE_OPTIONS O, FND_PROFILE_OPTION_VALUES V
where O.PROFILE_OPTION_NAME = option_name
and V.LEVEL_ID = 10002 and V.LEVEL_VALUE = to_char(appl_id)
and O.PROFILE_OPTION_ID = V.PROFILE_OPTION_ID
and O.APPLICATION_ID = V.APPLICATION_ID ;
for rec in ( select application_id,
application_short_name,
application_name
from fnd_application_vl
order by application_name )
loop
output_line(rec.application_name||' ('||
rec.application_short_name||') ... ',true );
for resp in ( select responsibility_id,
responsibility_name
from fnd_responsibility_vl
where application_id = rec.application_id
order by responsibility_name )
loop
get_resp_level (
option_name => 'PER_BUSINESS_GROUP_ID',
appl_id => rec.application_id,
resp_id => resp.responsibility_id,
option_value => l_resp_value,
defined => l_resp_defined ) ;