DBA Data[Home] [Help]

APPS.FND_PROFILE SQL Statements

The following lines contain the word 'select', 'insert', 'update' or 'delete':

Line: 14

   INSERTED    boolean := FALSE;            /*if at least a profile is stored */
Line: 176

      ** changes within that profile level to refresh it (delete it).
      */
      if (FND_CACHE_VERSIONS_PKG.check_version(USER_CACHE,USER_CACHE_VERSION)
         = FALSE) then
         if (USER_CACHE_VERSION = -1) then
            FND_CACHE_VERSIONS_PKG.add_cache_name(USER_CACHE);
Line: 184

            USER_NAME_TAB.DELETE();
Line: 185

            USER_VAL_TAB.DELETE();
Line: 195

            RESP_NAME_TAB.DELETE();
Line: 196

            RESP_VAL_TAB.DELETE();
Line: 206

            APPL_NAME_TAB.DELETE();
Line: 207

            APPL_VAL_TAB.DELETE();
Line: 217

            ORG_NAME_TAB.DELETE();
Line: 218

            ORG_VAL_TAB.DELETE();
Line: 228

            SERVER_NAME_TAB.DELETE();
Line: 229

            SERVER_VAL_TAB.DELETE();
Line: 239

            SERVRESP_NAME_TAB.DELETE();
Line: 240

            SERVRESP_VAL_TAB.DELETE();
Line: 250

            SITE_NAME_TAB.DELETE();
Line: 251

            SITE_VAL_TAB.DELETE();
Line: 369

   ** PUT - Set or Insert a profile option value in cache
   */
   procedure PUT(
      NAME                 in   varchar2, -- should be passed UPPER value
      VAL                  in   varchar2,
      nameTable            in out NOCOPY NAME_TAB_TYPE,
      valueTable           in out NOCOPY VAL_TAB_TYPE,
      PROFILE_HASH_VALUE   in binary_integer) is

      TABLE_INDEX binary_integer;
Line: 456

         INSERTED := TRUE; /* At least, a profile is stored */
Line: 473

   ** PUT - Set or Insert a profile option value into the generic PUT cache
   */
   procedure PUT(
      NAME in varchar2,
      VAL in varchar2)
   is
      /* Bug 5603664: APPSPERF:FND:OPTIMIZE FND_PROFILE.VALUE
      ** UPPER call is done early and value is passed on, which minimizes
      ** number of UPPER calls
      */
      NAME_UPPER  varchar2(80) := UPPER(NAME);
Line: 654

      select profile_option_value
      from   fnd_profile_option_values
      where  profile_option_id = pid
      and    application_id    = aid
      and    level_id          = lid
      and    level_value       = lval
      and    profile_option_value is not null;
Line: 666

      select profile_option_value
      from   fnd_profile_option_values
      where  profile_option_id = pid
      and    application_id = aid
      and    level_id = 10003
      and    level_value = lval
      and    level_value_application_id = laid
      and    profile_option_value is not null;
Line: 680

      select profile_option_value
      from   fnd_profile_option_values
      where  profile_option_id = pid
      and    application_id = aid
      and    level_id = 10007
      and    level_value = lval
      and    level_value_application_id = laid
      and    level_value2 = lval2
      and    profile_option_value is not null;
Line: 764

      select profile_option_id,
         application_id,
         site_enabled_flag ,
         app_enabled_flag ,
         resp_enabled_flag ,
         user_enabled_flag,
         org_enabled_flag ,
         server_enabled_flag,
         SERVERRESP_ENABLED_FLAG,
         hierarchy_type,
         user_changeable_flag     -- Bug 4257739
      from fnd_profile_options
      where profile_option_name = name_z --  Bug 5599946: Removed UPPER call
      and start_date_active  <= sysdate
      and nvl(end_date_active, sysdate) >= sysdate;
Line: 1343

         select   profile_option_id,
                  application_id,
                  site_enabled_flag ,
                  app_enabled_flag ,
                  resp_enabled_flag ,
                  user_enabled_flag,
                  org_enabled_flag ,
                  server_enabled_flag,
                  serverresp_enabled_flag,
                  hierarchy_type,
                  user_changeable_flag     -- Bug 4257739
         from fnd_profile_options
         where   profile_option_name = name_z
         and  start_date_active  <= sysdate
         and  nvl(end_date_active, sysdate) >= sysdate;
Line: 1364

         select profile_option_value
         from   fnd_profile_option_values
         where  profile_option_id = pid
         and  application_id = aid
         and  level_id = lid
         and  level_value = lval
         and  profile_option_value is not null;
Line: 1376

         select profile_option_value
         from fnd_profile_option_values
         where profile_option_id = pid
         and  application_id = aid
         and  level_id = 10003
         and  level_value = lval
         and  level_value_application_id = laid
         and  profile_option_value is not null;
Line: 1390

         select profile_option_value
         from fnd_profile_option_values
         where profile_option_id = pid
         and  application_id = aid
         and  level_id = 10007
         and  level_value = lval
         and  level_value_application_id = laid
         and  level_value2 = lval2
         and  profile_option_value is not null;
Line: 3065

         p_event_name=>'oracle.apps.fnd.profile.value.update',
         p_event_key=>event_key);
Line: 3134

      x_last_updated_by      NUMBER;
Line: 3135

      x_last_update_login    NUMBER;
Line: 3136

      x_last_update_date     DATE;
Line: 3148

      select application_id, profile_option_id
      from fnd_profile_options po
      where po.profile_option_name = X_NAME_UPPER
      /* Bug 5591340: FND_PROFILE.SAVE SHOULD NOT UPDATE VALUES FOR END_DATED
      ** PROFILE OPTIONS
      ** Added these date-sensitive conditions to prevent processing of
      ** end-dated profile options
      */
      and po.start_date_active <= sysdate
      and nvl(po.end_date_active, sysdate) >= sysdate;
Line: 3411

            FND_PROFILE_OPTION_VALUES_PKG.DELETE_ROW(x_application_id,
               x_profile_option_id, x_level_id, x_level_value_actual,
               X_LEVEL_VALUE_APP_ID, x_level_value2_actual);
Line: 3416

            FND_PROFILE_OPTION_VALUES_PKG.DELETE_ROW(x_application_id,
               x_profile_option_id, x_level_id, x_level_value_actual,
               X_LEVEL_VALUE_APP_ID);
Line: 3423

         x_last_update_date := SYSDATE;
Line: 3424

         x_last_updated_by := fnd_profile.value('USER_ID');
Line: 3425

         if x_last_updated_by is NULL then
            x_last_updated_by := -1;
Line: 3428

         x_last_update_login := fnd_profile.value('LOGIN_ID');
Line: 3429

         if x_last_update_login is NULL then
            x_last_update_login := -1;
Line: 3438

            FND_PROFILE_OPTION_VALUES_PKG.UPDATE_ROW(x_application_id,
               x_profile_option_id, x_level_id, x_level_value_actual,
               X_LEVEL_VALUE_APP_ID, x_level_value2_actual, X_VALUE,
               x_last_update_date, x_last_updated_by, x_last_update_login);
Line: 3444

            FND_PROFILE_OPTION_VALUES_PKG.UPDATE_ROW(x_application_id,
               x_profile_option_id, x_level_id, x_level_value_actual,
               X_LEVEL_VALUE_APP_ID, X_VALUE, x_last_update_date,
               x_last_updated_by, x_last_update_login);
Line: 3453

      ** This block of code was separated from the update/insert code block of
      ** SAVE() so that deleted values are properly reflected in level caches
      ** just like non-NULL values are cached when saved.
      ** Previously, only non-NULL values were being cached in level caches
      ** when a new non-NULL value was saved, such that when a value is
      ** deleted, the get apis would still return the previous cached value.
      */
      if (x_level_id = 10007) then
         invalidate_cache(x_level_name,x_level_value,x_level_value_app_id,
            X_NAME_UPPER,x_level_value2);
Line: 3542

      /* Bug 3203225: PREFERENCES NOT UPDATED ON FLY IN WF_ROLES VIEW
      ** needs to call FND_USER_PKG.User_Synch() whenever an update to
      ** ICX_LANGUAGE or ICX_TERRITORY is updated at the user level.
      */
      if ((X_NAME_UPPER = 'ICX_LANGUAGE')
         or (X_NAME_UPPER = 'ICX_TERRITORY')) then
         if ((X_LEVEL_NAME = 'USER') and (X_LEVEL_VALUE is not null)) then
            select user_name
            into   x_user_name
            from   fnd_user
            where  user_id = to_number(X_LEVEL_VALUE);
Line: 3607

      ** Check if fnd_cache_versions was updated. This refreshes level caches
      ** in order for value_specific to return accurate values should a new
      ** profile value be saved in another session. This will introduce a
      ** performance degradation which has been deemed necessary for
      ** value_specific return values.
      */
      CHECK_CACHE_VERSIONS();
Line: 3765

   **  The main usage for this routine would be in a SELECT statement where
   **  VALUE() is not allowed since it writes package state.
   **
   **  This routine does the same thing as VALUE(); it returns a profile value
Line: 3867

          ORG_NAME_TAB.DELETE();
Line: 3868

          ORG_VAL_TAB.DELETE();
Line: 3936

          NAME_TAB.DELETE();
Line: 3937

          VAL_TAB.DELETE();
Line: 3949

          USER_NAME_TAB.DELETE();
Line: 3950

          USER_VAL_TAB.DELETE();
Line: 3955

          RESP_NAME_TAB.DELETE();
Line: 3956

          RESP_VAL_TAB.DELETE();
Line: 3959

          SERVRESP_NAME_TAB.DELETE();
Line: 3960

          SERVRESP_VAL_TAB.DELETE();
Line: 3965

          APPL_NAME_TAB.DELETE();
Line: 3966

          APPL_VAL_TAB.DELETE();
Line: 3975

            RESP_NAME_TAB.DELETE();
Line: 3976

            RESP_VAL_TAB.DELETE();
Line: 3977

            SERVRESP_NAME_TAB.DELETE();
Line: 3978

            SERVRESP_VAL_TAB.DELETE();
Line: 3984

          SERVER_NAME_TAB.DELETE();
Line: 3985

          SERVER_VAL_TAB.DELETE();
Line: 3988

          SERVRESP_NAME_TAB.DELETE();
Line: 3989

          SERVRESP_VAL_TAB.DELETE();
Line: 4009

                    SELECT USER_NAME
                    INTO NAME
                    FROM FND_USER
                    WHERE USER_ID = user_id_z;
Line: 4048

                    SELECT RESPONSIBILITY_NAME
                    INTO NAME
                    FROM FND_RESPONSIBILITY_VL
                    WHERE RESPONSIBILITY_ID = responsibility_id_z
                    AND APPLICATION_ID = application_id_z;
Line: 4064

          select node_name
          into NAME
          from fnd_nodes
          where node_id = PROFILES_SERVER_ID;
Line: 4110

     if (not INSERTED) then
          return null;
Line: 4142

*      oracle.apps.fnd.profile.value.update event.  This function calls
*      FND_CACHE_VERSION_PKG.bump_version to increase the version of the
*      appropriate profile level cache.
*/
function bumpCacheVersion_RF (
     p_subscription_guid in raw,
     p_event in out NOCOPY WF_EVENT_T)
return varchar2 is

     l_event_key     varchar2(255);
Line: 4202

** DELETE - deletes the value of a profile option permanently from the
**          database, at any level.  This routine serves as a wrapper to
**          the SAVE routine which means that this routine can be used at
**          runtime or during patching.  Like the SAVE routine, this
**          routine will not actually commit the changes; the caller must
Line: 4212

**        FND_PROFILE.DELETE('P_NAME', 'SITE');
Line: 4213

**        FND_PROFILE.DELETE('P_NAME', 'APPL', 321532);
Line: 4214

**        FND_PROFILE.DELETE('P_NAME', 'RESP', 321532, 345234);
Line: 4215

**        FND_PROFILE.DELETE('P_NAME', 'USER', 123321);
Line: 4216

**        FND_PROFILE.DELETE('P_NAME', 'SERVER', 25);
Line: 4217

**        FND_PROFILE.DELETE('P_NAME', 'ORG', 204);
Line: 4218

**        FND_PROFILE.DELETE('P_NAME', 'SERVRESP', 321532, 345234, 25);
Line: 4219

**        FND_PROFILE.DELETE('P_NAME', 'SERVRESP', 321532, 345234, -1);
Line: 4220

**        FND_PROFILE.DELETE('P_NAME', 'SERVRESP', -1, -1, 25);
Line: 4225

function DELETE(
   X_NAME in varchar2,
      -- Profile name you are setting
   X_LEVEL_NAME in varchar2,
      -- Level that you're setting at: 'SITE','APPL','RESP','USER', etc.
   X_LEVEL_VALUE in varchar2 default NULL,
      -- Level value that you are setting at, e.g. user id for 'USER' level.
      -- X_LEVEL_VALUE is not used at site level.
   X_LEVEL_VALUE_APP_ID in varchar2 default NULL,
      -- Used for 'RESP' and 'SERVRESP' level; Resp Application_Id.
Line: 4240

   l_deleted   boolean;
Line: 4246

   l_deleted := SAVE(X_NAME,
                     NULL,
                     X_LEVEL_NAME,
                     X_LEVEL_VALUE,
                     X_LEVEL_VALUE_APP_ID,
                     X_LEVEL_VALUE2);
Line: 4253

   return l_deleted;