DBA Data[Home] [Help]

APPS.AD_STATS_UTIL_PKG SQL Statements

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

Line: 62

       select distinct('EXIST')
       into exist_flag
       from FND_HISTOGRAM_COLS
       where application_id = 50
       and table_name = 'AD_PATCH_COMMON_ACTIONS'
       and column_name = 'ACTION_CODE';
Line: 71

          fnd_stats.load_histogram_cols('INSERT', 50, 'AD_PATCH_COMMON_ACTIONS',
                                  'ACTION_CODE',NULL, hsize=>250);
Line: 80

       select distinct('EXIST')
       into exist_flag
       from FND_HISTOGRAM_COLS
       where application_id = 50
       and table_name = 'AD_FILES'
       and column_name = 'IS_FLAGGED_FILE';
Line: 89

          fnd_stats.load_histogram_cols('INSERT', 50,  'AD_FILES',
                                  'IS_FLAGGED_FILE', NULL, hsize=>250);
Line: 155

            p_rows_inserted_this_run            number,
            p_gather_stats_flag                 boolean,
            p_commit_flag                       boolean,
            p_gathered_stats_flag    out NOCOPY boolean)
is
  l_count_when_last_analyzed number := 0;
Line: 175

  validate_increment(p_rows_inserted_this_run);
Line: 178

    select
      nvl(to_number(attribute1), 0),
      nvl(to_number(attribute2), 0)
    into
      l_count_when_last_analyzed,
      l_count_till_last_run
    from ad_timestamps
    where type = 'COUNTS_FOR_ANALYZE'
    and attribute = p_subsystem_code;
Line: 195

  l_newcount := l_count_till_last_run + p_rows_inserted_this_run;
Line: 201

               to_char(p_rows_inserted_this_run));
Line: 214

      update ad_timestamps
      set attribute1 = to_char(l_newcount),
          attribute2 = to_char(l_newcount),
          timestamp = sysdate
      where type = 'COUNTS_FOR_ANALYZE'
      and attribute = p_subsystem_code;
Line: 225

      update ad_timestamps
      set attribute2 = to_char(l_newcount),
          timestamp = sysdate
      where type = 'COUNTS_FOR_ANALYZE'
      and attribute = p_subsystem_code;
Line: 253

      insert into ad_timestamps
      (
        type, attribute, timestamp,
        attribute1, attribute2
      ) values
      (
        'COUNTS_FOR_ANALYZE', p_subsystem_code, sysdate,
        to_char(l_count_when_last_analyzed), to_char(l_newcount)
      );