DBA Data[Home] [Help]

APPS.FII_FIN_CAT_MAINTAIN_PKG dependencies on FII_FIN_ITEM_LEAF_HIERS

Line 1590: FII_UTIL.truncate_table ('FII_FIN_ITEM_LEAF_HIERS', 'FII', g_retcode);

1586: FII_UTIL.truncate_table ('FII_FULL_FIN_ITEM_HIERS', 'FII', g_retcode);
1587: FII_UTIL.truncate_table ('FII_FIN_ITEM_HIERARCHIES', 'FII', g_retcode);
1588: FII_UTIL.truncate_table ('FII_FIN_CAT_MAPPINGS', 'FII', g_retcode);
1589: FII_UTIL.truncate_table ('FII_FIN_CAT_TYPE_ASSGNS', 'FII', g_retcode);
1590: FII_UTIL.truncate_table ('FII_FIN_ITEM_LEAF_HIERS', 'FII', g_retcode);
1591: FII_UTIL.truncate_table ('FII_FIN_CAT_LEAF_MAPS', 'FII', g_retcode);
1592:
1593: IF (FIIDIM_Debug) THEN
1594: FII_MESSAGE.Func_Succ(func_name => 'FII_FIN_CAT_MAINTAIN_PKG.'||

Line 1707: FII_UTIL.truncate_table ('FII_FIN_ITEM_LEAF_HIERS', 'FII', g_retcode);

1703:
1704: --Copy TMP hierarchy table to the final dimension table for Expense Analysis
1705: g_phase := 'Copy TMP hierarchy table to the final dimension table for Expense Analysis';
1706:
1707: FII_UTIL.truncate_table ('FII_FIN_ITEM_LEAF_HIERS', 'FII', g_retcode);
1708:
1709: INSERT /*+ APPEND */ INTO FII_FIN_ITEM_LEAF_HIERS (
1710: parent_level,
1711: parent_fin_cat_id,

Line 1709: INSERT /*+ APPEND */ INTO FII_FIN_ITEM_LEAF_HIERS (

1705: g_phase := 'Copy TMP hierarchy table to the final dimension table for Expense Analysis';
1706:
1707: FII_UTIL.truncate_table ('FII_FIN_ITEM_LEAF_HIERS', 'FII', g_retcode);
1708:
1709: INSERT /*+ APPEND */ INTO FII_FIN_ITEM_LEAF_HIERS (
1710: parent_level,
1711: parent_fin_cat_id,
1712: next_level,
1713: next_level_fin_cat_id,

Line 1758: FII_UTIL.Write_Log('Inserted ' || SQL%ROWCOUNT || ' rows into FII_FIN_ITEM_LEAF_HIERS');

1754: 'N'
1755: FROM FII_FIN_ITEM_HIER_GT;
1756:
1757: IF (FIIDIM_Debug) THEN
1758: FII_UTIL.Write_Log('Inserted ' || SQL%ROWCOUNT || ' rows into FII_FIN_ITEM_LEAF_HIERS');
1759: END IF;
1760:
1761: commit;
1762:

Line 1807: -- We have added an update statement on FII_FIN_ITEM_LEAF_HIERS. Hence, moved gathering statistics

1803: IF (FIIDIM_Debug) THEN
1804: FII_UTIL.Write_Log('Inserted ' || SQL%ROWCOUNT || ' rows into FII_FIN_ITEM_HIERARCHIES');
1805: END IF;
1806:
1807: -- We have added an update statement on FII_FIN_ITEM_LEAF_HIERS. Hence, moved gathering statistics
1808: -- for FII_FIN_ITEM_LEAF_HIERS table and its mlog at the end of procedure.
1809:
1810: --Call FND_STATS to collect statistics after re-populating the tables.
1811: --Will seed this in RSG

Line 1808: -- for FII_FIN_ITEM_LEAF_HIERS table and its mlog at the end of procedure.

1804: FII_UTIL.Write_Log('Inserted ' || SQL%ROWCOUNT || ' rows into FII_FIN_ITEM_HIERARCHIES');
1805: END IF;
1806:
1807: -- We have added an update statement on FII_FIN_ITEM_LEAF_HIERS. Hence, moved gathering statistics
1808: -- for FII_FIN_ITEM_LEAF_HIERS table and its mlog at the end of procedure.
1809:
1810: --Call FND_STATS to collect statistics after re-populating the tables.
1811: --Will seed this in RSG
1812: -- FND_STATS.gather_table_stats

Line 1915: UPDATE FII_FIN_ITEM_LEAF_HIERS

1911: Populate_FCT_denorm (p_initial_load => 'Y');
1912:
1913: g_phase := 'Update is_to_be_rolled_up_flag flag';
1914:
1915: UPDATE FII_FIN_ITEM_LEAF_HIERS
1916: SET is_to_be_rolled_up_flag = 'Y'
1917: WHERE next_level_fin_cat_id in ( SELECT fin_category_id
1918: FROM fii_fin_cat_type_assgns
1919: WHERE top_node_flag = 'Y' and

Line 1931: UPDATE fii_fin_item_leaf_hiers

1927:
1928: g_phase := 'Update top_node_fin_cat_type flag for OE';
1929:
1930: -- Updating the records for Category type OE. We give precedence to OE over TE.
1931: UPDATE fii_fin_item_leaf_hiers
1932: SET top_node_fin_cat_type = 'OE'
1933: WHERE next_level_fin_cat_id in (SELECT fin_category_id FROM fii_fin_cat_type_assgns
1934: WHERE top_node_flag = 'Y' AND fin_cat_type_code = 'OE')
1935: AND next_level_fin_cat_id <> parent_fin_cat_id;

Line 1941: UPDATE fii_fin_item_leaf_hiers

1937: g_phase := 'Update top_node_fin_cat_type flag for CGS';
1938:
1939: -- Updating the records for Category type OE. We give precedence to CGS over TE
1940: -- OE and CGS cannot be assigned to the same node so we need not worry about checking
1941: UPDATE fii_fin_item_leaf_hiers
1942: SET top_node_fin_cat_type = 'CGS'
1943: where next_level_fin_cat_id in (SELECT fin_category_id FROM fii_fin_cat_type_assgns
1944: WHERE top_node_flag = 'Y' AND fin_cat_type_code = 'CGS')
1945: and next_level_fin_cat_id <> parent_fin_cat_id;

Line 1950: UPDATE fii_fin_item_leaf_hiers fin

1946:
1947: g_phase := 'Update top_node_fin_cat_type flag for other category types';
1948:
1949: -- Updating the records for rest of the Category type.
1950: UPDATE fii_fin_item_leaf_hiers fin
1951: SET top_node_fin_cat_type = (SELECT fin_cat_type_code FROM fii_fin_cat_type_assgns
1952: WHERE fin_category_id = fin.next_level_fin_cat_id and fin_cat_type_code in ( 'R','TE'))
1953: WHERE (fin.next_level_fin_cat_id in (SELECT fin_category_id FROM fii_fin_cat_type_assgns
1954: WHERE top_node_flag = 'Y' AND fin_cat_type_code in ( 'R','TE'))

Line 1962: g_phase := 'gather_table_stats FII_FIN_ITEM_LEAF_HIERS';

1958:
1959:
1960:
1961: -- Call FND_STATS to collect statistics of the table.
1962: g_phase := 'gather_table_stats FII_FIN_ITEM_LEAF_HIERS';
1963:
1964: FND_STATS.gather_table_stats
1965: (ownname => g_schema_name,
1966: tabname => 'FII_FIN_ITEM_LEAF_HIERS');

Line 1966: tabname => 'FII_FIN_ITEM_LEAF_HIERS');

1962: g_phase := 'gather_table_stats FII_FIN_ITEM_LEAF_HIERS';
1963:
1964: FND_STATS.gather_table_stats
1965: (ownname => g_schema_name,
1966: tabname => 'FII_FIN_ITEM_LEAF_HIERS');
1967:
1968: g_phase := 'gather_table_stats MLOG$_FII_FIN_ITEM_LEAF_HI';
1969: FND_STATS.gather_table_stats
1970: (ownname => g_schema_name,

Line 2157: g_phase := 'DELETE FROM FII_FIN_ITEM_LEAF_HIERS';

2153: -- we need to maintain the permanent table FII_FIN_ITEM__LEAF_HIERS
2154: -- by diffing the 2 tables.
2155: -- The maintenance is done by 2 statements, one INSERT and one DELETE.
2156:
2157: g_phase := 'DELETE FROM FII_FIN_ITEM_LEAF_HIERS';
2158:
2159: DELETE FROM FII_FIN_ITEM_LEAF_HIERS
2160: WHERE
2161: (parent_level, parent_fin_cat_id, next_level, next_level_fin_cat_id,

Line 2159: DELETE FROM FII_FIN_ITEM_LEAF_HIERS

2155: -- The maintenance is done by 2 statements, one INSERT and one DELETE.
2156:
2157: g_phase := 'DELETE FROM FII_FIN_ITEM_LEAF_HIERS';
2158:
2159: DELETE FROM FII_FIN_ITEM_LEAF_HIERS
2160: WHERE
2161: (parent_level, parent_fin_cat_id, next_level, next_level_fin_cat_id,
2162: next_level_is_leaf_flag, is_leaf_flag, child_level, child_fin_cat_id,
2163: parent_flex_value_set_id, child_flex_value_set_id,

Line 2177: FROM FII_FIN_ITEM_LEAF_HIERS

2173: LEVEL2_fin_cat_ID,
2174: LEVEL3_fin_cat_ID,
2175: LEVEL4_fin_cat_ID,
2176: LEVEL5_fin_cat_ID
2177: FROM FII_FIN_ITEM_LEAF_HIERS
2178: MINUS
2179: SELECT parent_level, parent_fin_cat_id, next_level, next_level_fin_cat_id,
2180: next_level_is_leaf, is_leaf_flag, child_level, child_fin_cat_id,
2181: parent_flex_value_set_id, child_flex_value_set_id,

Line 2190: FII_UTIL.Write_Log('Deleted ' || SQL%ROWCOUNT || ' rows from FII_FIN_ITEM_LEAF_HIERS');

2186: LEVEL5_fin_cat_ID
2187: FROM FII_FIN_ITEM_HIER_GT);
2188:
2189: IF (FIIDIM_Debug) THEN
2190: FII_UTIL.Write_Log('Deleted ' || SQL%ROWCOUNT || ' rows from FII_FIN_ITEM_LEAF_HIERS');
2191: END IF;
2192:
2193: g_phase := 'Insert into FII_FIN_ITEM_LEAF_HIERS';
2194:

Line 2193: g_phase := 'Insert into FII_FIN_ITEM_LEAF_HIERS';

2189: IF (FIIDIM_Debug) THEN
2190: FII_UTIL.Write_Log('Deleted ' || SQL%ROWCOUNT || ' rows from FII_FIN_ITEM_LEAF_HIERS');
2191: END IF;
2192:
2193: g_phase := 'Insert into FII_FIN_ITEM_LEAF_HIERS';
2194:
2195: Insert into FII_FIN_ITEM_LEAF_HIERS (
2196: parent_level,
2197: parent_fin_cat_id,

Line 2195: Insert into FII_FIN_ITEM_LEAF_HIERS (

2191: END IF;
2192:
2193: g_phase := 'Insert into FII_FIN_ITEM_LEAF_HIERS';
2194:
2195: Insert into FII_FIN_ITEM_LEAF_HIERS (
2196: parent_level,
2197: parent_fin_cat_id,
2198: next_level,
2199: next_level_fin_cat_id,

Line 2264: FROM FII_FIN_ITEM_LEAF_HIERS);

2260: SYSDATE,
2261: FII_USER_ID,
2262: FII_LOGIN_ID,
2263: 'N'
2264: FROM FII_FIN_ITEM_LEAF_HIERS);
2265:
2266: IF (FIIDIM_Debug) THEN
2267: FII_UTIL.Write_Log('Inserted ' || SQL%ROWCOUNT || ' rows into FII_FIN_ITEM_LEAF_HIERS');
2268: END IF;

Line 2267: FII_UTIL.Write_Log('Inserted ' || SQL%ROWCOUNT || ' rows into FII_FIN_ITEM_LEAF_HIERS');

2263: 'N'
2264: FROM FII_FIN_ITEM_LEAF_HIERS);
2265:
2266: IF (FIIDIM_Debug) THEN
2267: FII_UTIL.Write_Log('Inserted ' || SQL%ROWCOUNT || ' rows into FII_FIN_ITEM_LEAF_HIERS');
2268: END IF;
2269:
2270: --Copy FII_FIN_ITEM_HIER_GT to the final (pruned) dimension table for DBI6.0
2271:

Line 2273: -- All data is now in the temporary table FII_FIN_ITEM_LEAF_HIERS,

2269:
2270: --Copy FII_FIN_ITEM_HIER_GT to the final (pruned) dimension table for DBI6.0
2271:
2272: -- Incremental Dimension Maintence
2273: -- All data is now in the temporary table FII_FIN_ITEM_LEAF_HIERS,
2274: -- we need to maintain the permanent table FII_FIN_ITEM_HIERARCHIES
2275: -- by diffing the 2 tables.
2276: -- The maintenance is done by 2 statements, one INSERT and one DELETE.
2277:

Line 2355: -- We have added an update statement on FII_FIN_ITEM_LEAF_HIERS. Hence, moved gathering statistics

2351: IF (FIIDIM_Debug) THEN
2352: FII_UTIL.Write_Log('Inserted ' || SQL%ROWCOUNT || ' rows into FII_FIN_ITEM_HIERARCHIES');
2353: END IF;
2354:
2355: -- We have added an update statement on FII_FIN_ITEM_LEAF_HIERS. Hence, moved gathering statistics
2356: -- for FII_FIN_ITEM_LEAF_HIERS table at the end of procedure.
2357:
2358: --Call FND_STATS to collect statistics after re-populating the tables.
2359: --Will seed this in RSG

Line 2356: -- for FII_FIN_ITEM_LEAF_HIERS table at the end of procedure.

2352: FII_UTIL.Write_Log('Inserted ' || SQL%ROWCOUNT || ' rows into FII_FIN_ITEM_HIERARCHIES');
2353: END IF;
2354:
2355: -- We have added an update statement on FII_FIN_ITEM_LEAF_HIERS. Hence, moved gathering statistics
2356: -- for FII_FIN_ITEM_LEAF_HIERS table at the end of procedure.
2357:
2358: --Call FND_STATS to collect statistics after re-populating the tables.
2359: --Will seed this in RSG
2360: -- FND_STATS.gather_table_stats

Line 2511: UPDATE FII_FIN_ITEM_LEAF_HIERS

2507: Populate_FCT_denorm (p_initial_load => 'N');
2508:
2509: g_phase := 'Update is_to_be_rolled_up_flag flag ';
2510:
2511: UPDATE FII_FIN_ITEM_LEAF_HIERS
2512: SET is_to_be_rolled_up_flag = 'Y'
2513: WHERE (next_level_fin_cat_id in ( SELECT fin_category_id
2514: FROM fii_fin_cat_type_assgns
2515: WHERE top_node_flag = 'Y' and

Line 2526: FII_UTIL.Write_Log('Updated ' || SQL%ROWCOUNT || ' rows into FII_FIN_ITEM_LEAF_HIERS');

2522: ))
2523: AND is_to_be_rolled_up_flag <> 'Y' ;
2524:
2525: IF (FIIDIM_Debug) THEN
2526: FII_UTIL.Write_Log('Updated ' || SQL%ROWCOUNT || ' rows into FII_FIN_ITEM_LEAF_HIERS');
2527: END IF;
2528:
2529: g_phase := 'Update top_node_fin_cat_type flag for OE';
2530:

Line 2532: UPDATE fii_fin_item_leaf_hiers

2528:
2529: g_phase := 'Update top_node_fin_cat_type flag for OE';
2530:
2531: -- Updating the records for Category type OE. We give precedence to OE over TE.
2532: UPDATE fii_fin_item_leaf_hiers
2533: SET top_node_fin_cat_type = 'OE'
2534: WHERE next_level_fin_cat_id IN (SELECT fin_category_id FROM fii_fin_cat_type_assgns
2535: WHERE top_node_flag = 'Y' AND fin_cat_type_code = 'OE')
2536: AND next_level_fin_cat_id <> parent_fin_cat_id

Line 2540: FII_UTIL.Write_Log('Updated ' || SQL%ROWCOUNT || ' rows into FII_FIN_ITEM_LEAF_HIERS');

2536: AND next_level_fin_cat_id <> parent_fin_cat_id
2537: AND (top_node_fin_cat_type <> 'OE' OR top_node_fin_cat_type is null);
2538:
2539: IF (FIIDIM_Debug) THEN
2540: FII_UTIL.Write_Log('Updated ' || SQL%ROWCOUNT || ' rows into FII_FIN_ITEM_LEAF_HIERS');
2541: END IF;
2542:
2543: g_phase := 'Update top_node_fin_cat_type flag for CGS';
2544:

Line 2547: UPDATE fii_fin_item_leaf_hiers

2543: g_phase := 'Update top_node_fin_cat_type flag for CGS';
2544:
2545: -- Updating the records for Category type OE. We give precedence to CGS over TE
2546: -- OE and CGS cannot be assigned to the same node so we need not worry about checking
2547: UPDATE fii_fin_item_leaf_hiers
2548: SET top_node_fin_cat_type = 'CGS'
2549: where next_level_fin_cat_id IN (SELECT fin_category_id FROM fii_fin_cat_type_assgns
2550: WHERE top_node_flag = 'Y' AND fin_cat_type_code = 'CGS')
2551: AND next_level_fin_cat_id <> parent_fin_cat_id

Line 2555: FII_UTIL.Write_Log('Updated ' || SQL%ROWCOUNT || ' rows into FII_FIN_ITEM_LEAF_HIERS');

2551: AND next_level_fin_cat_id <> parent_fin_cat_id
2552: AND (top_node_fin_cat_type <> 'CGS' OR top_node_fin_cat_type is null);
2553:
2554: IF (FIIDIM_Debug) THEN
2555: FII_UTIL.Write_Log('Updated ' || SQL%ROWCOUNT || ' rows into FII_FIN_ITEM_LEAF_HIERS');
2556: END IF;
2557:
2558: g_phase := 'Update top_node_fin_cat_type flag for other category types';
2559:

Line 2561: UPDATE fii_fin_item_leaf_hiers fin

2557:
2558: g_phase := 'Update top_node_fin_cat_type flag for other category types';
2559:
2560: -- Updating the records for rest of the Category type.
2561: UPDATE fii_fin_item_leaf_hiers fin
2562: SET top_node_fin_cat_type = (SELECT fin_cat_type_code FROM fii_fin_cat_type_assgns
2563: WHERE fin_category_id = fin.next_level_fin_cat_id and fin_cat_type_code in ( 'R','TE'))
2564: WHERE (fin.next_level_fin_cat_id in (SELECT fin_category_id FROM fii_fin_cat_type_assgns
2565: WHERE top_node_flag = 'Y' AND fin_cat_type_code in ( 'R','TE'))

Line 2576: UPDATE fii_fin_item_leaf_hiers fin

2572:
2573:
2574: -- This update statement is added for the nodes for which there is no category assigned now, but they had one before
2575: -- This is a valid case
2576: UPDATE fii_fin_item_leaf_hiers fin
2577: set top_node_fin_cat_type = NULL
2578: where next_level_fin_cat_id in (SELECT next_level_fin_cat_id from fii_fin_item_leaf_hiers
2579: WHERE top_node_fin_cat_type is not null
2580: MINUS

Line 2578: where next_level_fin_cat_id in (SELECT next_level_fin_cat_id from fii_fin_item_leaf_hiers

2574: -- This update statement is added for the nodes for which there is no category assigned now, but they had one before
2575: -- This is a valid case
2576: UPDATE fii_fin_item_leaf_hiers fin
2577: set top_node_fin_cat_type = NULL
2578: where next_level_fin_cat_id in (SELECT next_level_fin_cat_id from fii_fin_item_leaf_hiers
2579: WHERE top_node_fin_cat_type is not null
2580: MINUS
2581: SELECT fin_category_id FROM fii_fin_cat_type_assgns
2582: WHERE top_node_flag = 'Y' AND fin_cat_type_code in ( 'R','TE', 'OE', 'CGS')

Line 2587: FII_UTIL.Write_Log('Updated ' || SQL%ROWCOUNT || ' rows into FII_FIN_ITEM_LEAF_HIERS');

2583: )
2584: AND next_level_fin_cat_id <> parent_fin_cat_id;
2585:
2586: IF (FIIDIM_Debug) THEN
2587: FII_UTIL.Write_Log('Updated ' || SQL%ROWCOUNT || ' rows into FII_FIN_ITEM_LEAF_HIERS');
2588: END IF;
2589:
2590: -- Call FND_STATS to collect statistics of the table.
2591: g_phase := 'gather_table_stats FII_FIN_ITEM_LEAF_HIERS';

Line 2591: g_phase := 'gather_table_stats FII_FIN_ITEM_LEAF_HIERS';

2587: FII_UTIL.Write_Log('Updated ' || SQL%ROWCOUNT || ' rows into FII_FIN_ITEM_LEAF_HIERS');
2588: END IF;
2589:
2590: -- Call FND_STATS to collect statistics of the table.
2591: g_phase := 'gather_table_stats FII_FIN_ITEM_LEAF_HIERS';
2592:
2593: FND_STATS.gather_table_stats
2594: (ownname => g_schema_name,
2595: tabname => 'FII_FIN_ITEM_LEAF_HIERS');

Line 2595: tabname => 'FII_FIN_ITEM_LEAF_HIERS');

2591: g_phase := 'gather_table_stats FII_FIN_ITEM_LEAF_HIERS';
2592:
2593: FND_STATS.gather_table_stats
2594: (ownname => g_schema_name,
2595: tabname => 'FII_FIN_ITEM_LEAF_HIERS');
2596:
2597: -- Bug 4200473. Not to analyze MLOG in incremental run.
2598: -- As per performance teams suggestions.
2599: