DBA Data[Home] [Help]

APPS.OPI_DBI_INV_VALUE_INIT_PKG dependencies on OPI_DBI_INV_VALUE_INIT_PKG

Line 1: Package Body OPI_DBI_INV_VALUE_INIT_PKG AS

1: Package Body OPI_DBI_INV_VALUE_INIT_PKG AS
2: /*$Header: OPIDIVIB.pls 120.31 2008/03/07 09:18:26 sdiwakar noship $ */
3:
4: g_sysdate CONSTANT DATE := SYSDATE;
5: g_user_id CONSTANT NUMBER := nvl(fnd_global.user_id, -1);

Line 14: g_pkg_name CONSTANT VARCHAR2(200) := 'OPI_DBI_INV_VALUE_INIT_PKG';

10: g_global_sec_curr_code VARCHAR2(10);
11: g_global_rate_type VARCHAR2(32);
12: g_global_sec_rate_type VARCHAR2(32);
13: g_R12_date DATE;
14: g_pkg_name CONSTANT VARCHAR2(200) := 'OPI_DBI_INV_VALUE_INIT_PKG';
15: g_opi_schema VARCHAR2(10);
16: --OPI_DBI_RPT_UTIL_PKG.g_pk_uom_conversion number;
17: -- User Defined Exceptions
18:

Line 25: -- -->OPI_DBI_INV_VALUE_INIT_PKG.SEED_INV_TYPE_CODE

21: UOM_CONV_ERROR EXCEPTION;
22: PRAGMA EXCEPTION_INIT (UOM_CONV_ERROR, -20901);
23:
24: --RUN_FIRST_ETL
25: -- -->OPI_DBI_INV_VALUE_INIT_PKG.SEED_INV_TYPE_CODE
26: --
27: -- -->RUN_DISCRETE_FIRST_ETL
28: -- --->clean_staging_tables
29: -- --->OPI_DBI_BOUNDS_PKG.MAINTAIN_OPI_DBI_LOGS

Line 1452: OPI_DBI_INV_VALUE_INIT_PKG.get_onhand_balance;

1448: l_debug_msg := 'Extracting On Hand Inception Balances into its staging table ...';
1449: OPI_DBI_BOUNDS_PKG.write (g_pkg_name,l_proc_name,l_stmt_num, l_debug_msg );
1450: END IF;
1451: -- collect on hand inception balance
1452: OPI_DBI_INV_VALUE_INIT_PKG.get_onhand_balance;
1453:
1454: l_stmt_num := 20;
1455: IF l_debug_mode = 'Y' and upper(l_module_name) like 'BIS%' then
1456: l_debug_msg := 'Extracting InTransit Inception Balances into its staging table ...';

Line 1460: OPI_DBI_INV_VALUE_INIT_PKG.get_intransit_balance;

1456: l_debug_msg := 'Extracting InTransit Inception Balances into its staging table ...';
1457: OPI_DBI_BOUNDS_PKG.write (g_pkg_name,l_proc_name,l_stmt_num, l_debug_msg );
1458: END IF;
1459: -- collect intransit inception balance
1460: OPI_DBI_INV_VALUE_INIT_PKG.get_intransit_balance;
1461:
1462: l_stmt_num := 30;
1463: IF l_debug_mode = 'Y' and upper(l_module_name) like 'BIS%' then
1464: l_debug_msg := 'Extracting Work In Process Inception Balances into its staging table ...';

Line 1468: OPI_DBI_INV_VALUE_INIT_PKG.get_wip_balance;

1464: l_debug_msg := 'Extracting Work In Process Inception Balances into its staging table ...';
1465: OPI_DBI_BOUNDS_PKG.write (g_pkg_name,l_proc_name,l_stmt_num, l_debug_msg );
1466: END IF;
1467: -- collect WIP inception balance
1468: OPI_DBI_INV_VALUE_INIT_PKG.get_wip_balance;
1469:
1470: l_stmt_num := 40;
1471: IF l_debug_mode = 'Y' and upper(l_module_name) like 'BIS%' then
1472: l_debug_msg := 'Costing Inception balances ODM ...';

Line 1476: OPI_DBI_INV_VALUE_INIT_PKG.cost_discrete_inception_qty;

1472: l_debug_msg := 'Costing Inception balances ODM ...';
1473: OPI_DBI_BOUNDS_PKG.write (g_pkg_name,l_proc_name,l_stmt_num, l_debug_msg );
1474: END IF;
1475: -- cost discrete inception onhand and intransit quantities
1476: OPI_DBI_INV_VALUE_INIT_PKG.cost_discrete_inception_qty;
1477:
1478: l_stmt_num := 50;
1479: IF l_debug_mode = 'Y' and upper(l_module_name) like 'BIS%' then
1480: l_debug_msg := 'Costing Inception balances OPM ...';

Line 1484: OPI_DBI_INV_VALUE_INIT_PKG.cost_opm_inception_qty;

1480: l_debug_msg := 'Costing Inception balances OPM ...';
1481: OPI_DBI_BOUNDS_PKG.write (g_pkg_name,l_proc_name,l_stmt_num, l_debug_msg );
1482: END IF;
1483: -- cost OPM inception onhand and intransit quantities
1484: OPI_DBI_INV_VALUE_INIT_PKG.cost_opm_inception_qty;
1485:
1486: commit;
1487:
1488: --execute immediate 'alter session disable parallel query';

Line 2707: OPI_DBI_INV_VALUE_INIT_PKG.clean_staging_tables('PRE_INIT');

2703: l_debug_msg := 'Calling Clean staging table PRE INIT';
2704: OPI_DBI_BOUNDS_PKG.write (g_pkg_name,l_proc_name,l_stmt_num, l_debug_msg );
2705: END IF;
2706:
2707: OPI_DBI_INV_VALUE_INIT_PKG.clean_staging_tables('PRE_INIT');
2708:
2709: l_stmt_num := 20;
2710: IF l_debug_mode = 'Y' and upper(l_module_name) like 'BIS%' then
2711: l_debug_msg := 'Setting up bound for Inventory Initial Load ';

Line 2732: OPI_DBI_INV_VALUE_INIT_PKG.extract_inventory_txn_qty;

2728: l_debug_msg := 'Collecting OPI , OPM Initial Load Inventory Quantities ';
2729: OPI_DBI_BOUNDS_PKG.write (g_pkg_name,l_proc_name,l_stmt_num, l_debug_msg );
2730: END IF;
2731:
2732: OPI_DBI_INV_VALUE_INIT_PKG.extract_inventory_txn_qty;
2733: -- even this procedure has a commit as it has two extracts and each one run in parallel append mode.
2734: commit;
2735:
2736: l_stmt_num := 40;

Line 2742: OPI_DBI_INV_VALUE_INIT_PKG.extract_inventory_txn_value;

2738: l_debug_msg := 'Collecting OPI, OPM Initial Load Inventory Values ';
2739: OPI_DBI_BOUNDS_PKG.write (g_pkg_name,l_proc_name,l_stmt_num, l_debug_msg );
2740: END IF;
2741:
2742: OPI_DBI_INV_VALUE_INIT_PKG.extract_inventory_txn_value;
2743: commit;
2744:
2745: l_stmt_num := 50;
2746: IF l_debug_mode = 'Y' and upper(l_module_name) like 'BIS%' then

Line 2751: OPI_DBI_INV_VALUE_INIT_PKG.get_intransit_initial_load;

2747: l_debug_msg := 'Collecting OPI , OPM Intransit Intial Load ';
2748: OPI_DBI_BOUNDS_PKG.write (g_pkg_name,l_proc_name,l_stmt_num, l_debug_msg );
2749: END IF;
2750:
2751: OPI_DBI_INV_VALUE_INIT_PKG.get_intransit_initial_load;
2752: commit;
2753:
2754: IF l_debug_mode = 'Y' and upper(l_module_name) like 'BIS%' then
2755: l_debug_msg := 'Exit from RUN_DISCRETE_FIRST_ETL';

Line 2883: OPI_DBI_INV_VALUE_INIT_PKG.seed_inv_type_codes; -- No changes for R12

2879: l_debug_msg := 'Calling Procedure seed inv codeType ';
2880: OPI_DBI_BOUNDS_PKG.write (g_pkg_name,l_proc_name,l_stmt_num, l_debug_msg );
2881: END IF;
2882: -- This will populate data for INV type report
2883: OPI_DBI_INV_VALUE_INIT_PKG.seed_inv_type_codes; -- No changes for R12
2884: commit;
2885:
2886: l_stmt_num := 35;
2887: if (bis_collection_utilities.setup ( p_object_name => 'OPI_DBI_INV_VALUE_F') = false) then

Line 2899: OPI_DBI_INV_VALUE_INIT_PKG.Run_Discrete_First_ETL ;

2895: END IF;
2896:
2897: -- collects data from post r12 model for process as well as discrete organizations
2898: -- collects onhand quantity, onhand value, intransit qty and value, wip value
2899: OPI_DBI_INV_VALUE_INIT_PKG.Run_Discrete_First_ETL ;
2900:
2901: l_stmt_num :=50;
2902: IF l_debug_mode = 'Y' and upper(l_module_name) like 'BIS%' then
2903: l_debug_msg := 'Getting Convergence date. ';

Line 2946: OPI_DBI_INV_VALUE_INIT_PKG.get_inception_inv_balance;

2942: END IF;
2943:
2944: -- collects inception balance from staging tables above and also costs the onhand and
2945: -- intransit quantities
2946: OPI_DBI_INV_VALUE_INIT_PKG.get_inception_inv_balance;
2947:
2948: l_stmt_num :=80;
2949: IF l_debug_mode = 'Y' and upper(l_module_name) like 'BIS%' then
2950: l_debug_msg := 'Checking for Conversion Rate. ';

Line 2977: OPI_DBI_INV_VALUE_INIT_PKG.merge_initial_load;

2973: -- 3. OPI_DBI_INTRANSIT_STG -- Intransit Qty and Value
2974: -- 4. OPI_DBI_INV_BEG_STG -- Inception qty and value
2975: -- 5. OPI_DBI_ONHAND_STG -- On hand value
2976: -- 6. OPI_DBI_CONVERSION_RATES -- currency conversion rates
2977: OPI_DBI_INV_VALUE_INIT_PKG.merge_initial_load;
2978:
2979: l_stmt_num :=100;
2980: IF l_debug_mode = 'Y' and upper(l_module_name) like 'BIS%' then
2981: l_debug_msg := 'Starting Clean staging table post initial Load. ';

Line 2985: OPI_DBI_INV_VALUE_INIT_PKG.clean_staging_tables ('POST_INIT');

2981: l_debug_msg := 'Starting Clean staging table post initial Load. ';
2982: OPI_DBI_BOUNDS_PKG.write (g_pkg_name,l_proc_name,l_stmt_num, l_debug_msg );
2983: END IF;
2984: -- truncate the data in staging table
2985: OPI_DBI_INV_VALUE_INIT_PKG.clean_staging_tables ('POST_INIT');
2986:
2987: l_stmt_num :=110;
2988: IF l_debug_mode = 'Y' and upper(l_module_name) like 'BIS%' then
2989: l_debug_msg := 'Starting Period close adjustment. ';

Line 3053: End OPI_DBI_INV_VALUE_INIT_PKG;

3049: RAISE;
3050:
3051: END RUN_FIRST_ETL;
3052:
3053: End OPI_DBI_INV_VALUE_INIT_PKG;