24: 'ISC_DBI_FULL_PEGGING_F');
25:
26: g_small_snapshots TableList := TableList('ISC_DBI_PLAN_ORG_SNAPSHOTS', 'ISC_DBI_PLAN_SNAPSHOTS');
27: g_large_snapshots TableList := TableList('ISC_DBI_SUPPLIES_SNAPSHOTS','ISC_DBI_INV_DETAIL_SNAPSHOTS',
28: 'ISC_DBI_RES_SUM_SNAPSHOTS', 'ISC_DBI_SHORTFALL_SNAPSHOTS');
29:
30: FUNCTION DROP_PLANS(p_plan_id NUMBER) RETURN NUMBER IS
31:
32: l_delete_stmt VARCHAR2(2000);
2034: FII_UTIL.Print_Timer('Inserted '|| sql%rowcount ||' rows into isc_dbi_inv_detail_snapshots in');
2035: -- COMMIT;
2036:
2037: -- ----------------------------------
2038: -- Collect ISC_DBI_RES_SUM_SNAPSHOTS
2039: -- ----------------------------------
2040:
2041: BIS_COLLECTION_UTILITIES.put_line(' ');
2042: BIS_COLLECTION_UTILITIES.put_line('Begin to insert data into isc_dbi_res_sum_snapshots.');
2038: -- Collect ISC_DBI_RES_SUM_SNAPSHOTS
2039: -- ----------------------------------
2040:
2041: BIS_COLLECTION_UTILITIES.put_line(' ');
2042: BIS_COLLECTION_UTILITIES.put_line('Begin to insert data into isc_dbi_res_sum_snapshots.');
2043: FII_UTIL.Start_Timer;
2044:
2045: INSERT /*+ APPEND PARALLEL(F) */
2046: INTO isc_dbi_res_sum_snapshots F(
2042: BIS_COLLECTION_UTILITIES.put_line('Begin to insert data into isc_dbi_res_sum_snapshots.');
2043: FII_UTIL.Start_Timer;
2044:
2045: INSERT /*+ APPEND PARALLEL(F) */
2046: INTO isc_dbi_res_sum_snapshots F(
2047: SNAPSHOT_ID,
2048: ORGANIZATION_ID,
2049: START_DATE,
2050: PERIOD_TYPE_ID,
2078: GROUP BY snapshot_id, ires.organization_id, ires.resource_id, ires.organization_type, ires.department_id,
2079: grouping sets(ent_year_start_date, ent_qtr_start_date, ent_period_start_date);
2080:
2081: FII_UTIL.Stop_Timer;
2082: FII_UTIL.Print_Timer('Inserted '|| sql%rowcount ||' rows into isc_dbi_res_sum_snapshots in');
2083: -- COMMIT;
2084: END IF;
2085:
2086: RETURN(1);