0% found this document useful (0 votes)
101 views3 pages

Get Profile Option

This SQL query selects profile option values associated with responsibilities from various tables, including the responsibility name, key, end date, profile option name and value. It decodes the profile option name to return a meaningful value such as a security profile name, flex value description, or lookup value meaning based on the profile option name. The results are ordered by responsibility name.

Uploaded by

jarrux
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as TXT, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
101 views3 pages

Get Profile Option

This SQL query selects profile option values associated with responsibilities from various tables, including the responsibility name, key, end date, profile option name and value. It decodes the profile option name to return a meaningful value such as a security profile name, flex value description, or lookup value meaning based on the profile option name. The results are ordered by responsibility name.

Uploaded by

jarrux
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as TXT, PDF, TXT or read online on Scribd
You are on page 1/ 3

Avec user :

SELECT
po.profile_option_name as name
, po.user_profile_option_name
, decode(to_char(pov.level_id),'10001','SITE','10002','APP','10003','RESP','1000
5','SERVER','10006','ORG','10004','USER', '???') as "LEVEL"
, decode(to_char(pov.level_id),'10001','','10002', app.application_short_name,'1
0003', rsp.responsibility_key,'10005', svr.node_name,'10006', org.name,'10004',
usr.user_name,'???') as context
, pov.profile_option_value as value
FROM
fnd_profile_options_vl po
, fnd_profile_option_values pov
, fnd_user usr
, fnd_application app
, fnd_responsibility rsp
, fnd_nodes svr
, hr_operating_units org
WHERE 1=1
AND pov.application_id = po.application_id
AND pov.profile_option_id = po.profile_option_id
AND usr.user_id (+) = pov.level_value
AND rsp.application_id (+) = pov.level_value_application_id
AND rsp.responsibility_id (+) = pov.level_value
AND app.application_id (+) = pov.level_value
AND svr.node_id (+) = pov.level_value
and org.organization_id (+) = pov.level_value
and po.user_profile_option_name='Concurrent:Active Request Limit'
ORDER BY 1, pov.level_id, 5

Avec
SELECT DISTINCT
tr.responsibility_name,
r.RESPONSIBILITY_KEY,
r.end_date,
fpotl.user_profile_option_name,
fpov.profile_option_value,
DECODE (
fpotl.user_profile_option_name,
'SLI: Project LOV Security', (SELECT security_profile_name
FROM PER_SECURITY_PROFILES S,
PER_BUSINESS_GROUPS O
WHERE O.BUSINESS_GROUP_ID(+) =
S.BUSINESS_GROUP_ID
AND TO_CHAR (
s.security_profile_id) =
fpov.profile_option_valu
e),
'XXSLI Balancing Segment', (SELECT ffvt.flex_value_meaning
FROM fnd_flex_values_tl ffvt
WHERE ffvt.language = 'US'
AND TO_CHAR (ffvt.flex_value_id)
=
fpov.profile_option_value)
,
'GL: Data Access Set', (SELECT name
FROM gl_access_sets gas
WHERE TO_CHAR (gas.access_set_id) =
fpov.profile_option_value),
'HR: Security Profile', (SELECT security_profile_name
FROM per_security_profiles sp
WHERE TO_CHAR (sp.security_profile_id) =
fpov.profile_option_value),
'HR:Business Group', (SELECT name
FROM hr_all_organization_units org
WHERE TO_CHAR (org.organization_id) =
fpov.profile_option_value),
'MO: Default Operating Unit', (SELECT name
FROM hr_all_organization_units org
WHERE TO_CHAR (org.organization_id)
=
fpov.profile_option_value),
'MO: Operating Unit', (SELECT name
FROM hr_all_organization_units org
WHERE TO_CHAR (org.organization_id) =
fpov.profile_option_value),
'MO: Security Profile', (SELECT security_profile_name
FROM per_security_profiles sp
WHERE TO_CHAR (sp.security_profile_id) =
fpov.profile_option_value),
'XXSLI iExpense Auditor', (SELECT ffvt.description
FROM fnd_flex_values_tl ffvt
WHERE ffvt.language = 'US'
AND TO_CHAR (ffvt.flex_value_id) =
fpov.profile_option_value),
'HR:User Type', (SELECT meaning
FROM fnd_lookup_values flv
WHERE flv.lookup_type = 'HR_USER_TYPE'
AND flv.language = 'US'
AND flv.lookup_code =
fpov.profile_option_value),
'PJI: Organization Security Profile', (SELECT security_profile_name
FROM per_security_profiles
sp
WHERE TO_CHAR (
sp.security_profile
_id) =
fpov.profile_option
_value),
'FND: Debug Log Level', (SELECT meaning
FROM fnd_lookup_values flv
WHERE flv.lookup_type =
'AFLOG_LEVELS'
AND flv.language = 'US'
AND flv.lookup_code =
fpov.profile_option_value),
'SLI SLA APPROVAL PROFILE', (SELECT meaning
FROM fnd_lookup_values flv
WHERE flv.lookup_type =
'SLI_SLA_APPROVAL_PROFILE
'
AND flv.language = 'US'
AND flv.lookup_code =
fpov.profile_option_value
),
fpov.profile_option_value)
visible_profile_value -- default
FROM applsys.fnd_responsibility_tl tr,
applsys.fnd_responsibility r,
fnd_profile_options fpovl,
applsys.fnd_profile_option_values fpov,
applsys.fnd_profile_options fpo,
applsys.fnd_profile_options_tl fpotl
WHERE r.responsibility_id = tr.responsibility_id
AND r.application_id = tr.application_id
AND fpov.PROFILE_OPTION_ID = fpovl.PROFILE_OPTION_ID(+)
AND fpov.level_value(+) = r.responsibility_id
AND fpov.level_id(+) = 10003 --responsibility level = 10003 user = 1000
1 level = 10000 application = 10002
AND fpo.profile_option_id(+) = fpov.profile_option_id
AND fpotl.profile_option_name(+) = fpo.profile_option_name
AND tr.responsibility_name LIKE 'SLI%'
AND NVL (r.end_date, SYSDATE + 1) > SYSDATE
AND fpotl.language(+) = 'US'
AND tr.language = 'US' -- English resp only
ORDER BY responsibility_name

You might also like