Query to Find Profile Option Values at All Levels in Oracle Apps

A profile option in Oracle EBS can be set at several levels, and the most specific one wins (user over responsibility over application over site). All values are in FND_PROFILE_OPTION_VALUES, where LEVEL_ID says the level and LEVEL_VALUE holds the ID of the user, responsibility, application, server or organization. The query below decodes both, so you see each value with a readable level name and level value.

SQL: profile option values at every level

  SELECT fa.application_name,
         fpov.level_id,
         fa.application_short_name,
         fpo.USER_PROFILE_OPTION_NAME,
         fpo.PROFILE_OPTION_NAME,
         DECODE (fpov.level_id,
                 10001, 'Site',
                 10002, 'Application',
                 10003, 'Responsibility',
                 10004, 'User',
                 10005, 'Server',
                 10006, 'Organization',
                 10007, 'ServResp',
                 'Unknown')
            Level_name,
         DECODE (fpov.LEVEL_ID,
                 10001, NULL,
                 10002, fal.APPLICATION_NAME,
                 10003, frt.RESPONSIBILITY_NAME,
                 10004, fu.USER_NAME,
                 10005, svr.node_name,
                 10006, org.name,
                 10007,    (SELECT n.node_name
                              FROM fnd_nodes n
                             WHERE n.node_id = level_value2)
                        || '/'
                        || (DECODE (fpov.level_value,
                                    -1, 'Default',
                                    (SELECT responsibility_key
                                       FROM fnd_responsibility
                                      WHERE responsibility_id = level_value))),
                 fpov.level_id)
            Level_value,
         fpov.PROFILE_OPTION_VALUE
    FROM fnd_profile_options_vl  fpo,
         fnd_profile_option_values fpov,
         fnd_application_vl      fa,
         fnd_application_vl      fal,
         fnd_responsibility_vl   frt,
         fnd_user                fu,
         fnd_nodes               svr,
         hr_operating_units      org
   WHERE     fpo.profile_option_id = fpov.profile_option_id
         AND fa.application_id = fpo.application_id
         AND fpov.LEVEL_VALUE = fal.APPLICATION_ID(+)
         AND fpov.LEVEL_VALUE = frt.RESPONSIBILITY_ID(+)
         AND fpov.LEVEL_VALUE = fu.USER_ID(+)
         AND fpov.LEVEL_VALUE_APPLICATION_ID = frt.APPLICATION_ID(+)
         AND fpov.level_value = svr.node_id(+)
         AND fpov.level_value = org.organization_id(+)
         AND fpo.USER_PROFILE_OPTION_NAME LIKE
                '<profile option name>'
ORDER BY USER_PROFILE_OPTION_NAME;

Profile option levels

LEVEL_IDLevelLEVEL_VALUE refers to
10001Site0
10002ApplicationFND_APPLICATION.APPLICATION_ID
10003ResponsibilityFND_RESPONSIBILITY.RESPONSIBILITY_ID
10004UserFND_USER.USER_ID
10005ServerFND_NODES.NODE_ID
10006OrganizationHR_ALL_ORGANIZATION_UNITS.ORGANIZATION_ID
10007Server + ResponsibilityResponsibility ID, with server in LEVEL_VALUE2

Filter on fpo.user_profile_option_name to check one profile. To get the effective value for the current session, use FND_PROFILE.VALUE('INTERNAL_NAME') after initializing the context with FND_GLOBAL.APPS_INITIALIZE.

Which table stores profile option values in Oracle EBS?

FND_PROFILE_OPTION_VALUES, with the profile definitions in FND_PROFILE_OPTIONS and FND_PROFILE_OPTIONS_TL.

Which profile level takes priority?

The most specific level set: User, then Responsibility, then Application, then Site (Server and Organization apply only to profiles that support them).

Related queries

Related posts: Upload your own post and refer it anywhere anytime: