DBA Data[Home] [Help]

PACKAGE: APPS.OPI_DBI_COMMON_MOD_INIT_PKG

Source


1 PACKAGE opi_dbi_common_mod_init_pkg AS
2 /*$Header: OPIDCMODIS.pls 120.1 2005/08/10 01:37:35 sberi noship $ */
3 
4 /*++++++++++++++++++++++++++++++++++++++++*/
5 /* Common Module Constants */
6 /*++++++++++++++++++++++++++++++++++++++++*/
7 
8 /*  All DBI ETLs have a numeric ETL ID for identification. The ETL
9     functionality to etl_id mapping is defined as: */
10 
11 JOB_TXN_ETL CONSTANT NUMBER := 1;           -- Job Transaction Staging ETL (WIP Completions, Actual Usage and Scrap)
12 ACTUAL_RES_ETL CONSTANT NUMBER := 2;        -- Actual Resource Usage
13 RESOURCE_VAR_ETL CONSTANT NUMBER := 3;      -- Resource Variance
14 JOB_MASTER_ETL CONSTANT NUMBER := 4;        -- Job Master
15 
16 /*  All ETLs can have one of two sources: */
17 OPI_SOURCE CONSTANT NUMBER := 1;
18 OPM_SOURCE CONSTANT NUMBER := 2;
19 
20 /*  ETLs can have to stop for multiple reasons. The stop reason
21     codes are defined as follows: */
22 STOP_UNCOSTED CONSTANT NUMBER := 1;
23 STOP_ALL_COSTED CONSTANT NUMBER := 2;
24 
25 /*----------------------------------------*/
26 
27 
28 
29 /* Outer wrapper routine for to run the common module */
30 PROCEDURE run_common_module_init (errbuf OUT NOCOPY VARCHAR2,
31                                   retcode OUT NOCOPY NUMBER);
32 
33 
34 /* Compute the initial bounds for all ETLs and all sources.
35 */
36 PROCEDURE compute_initial_etl_bounds (errbuf OUT NOCOPY VARCHAR2,
37                                       retcode OUT NOCOPY NUMBER,
38                                       p_global_start_date IN DATE,
39 									  p_opi_schema IN VARCHAR2);
40 
41 /* API for ETLs to ensure that bounds are setup correctly for them */
42 FUNCTION init_end_bounds_setup (p_etl_id IN NUMBER, p_source IN NUMBER)
43     RETURN BOOLEAN;
44 
45 /* API for ETL initial loads to that they are mean to run and not the
46    initial loads
47  */
48 FUNCTION run_initial_load (p_etl_id IN NUMBER, p_source IN NUMBER)
49     RETURN BOOLEAN;
50 
51 
52 /* Some Utilities for initial and incremental load packages */
53 
54 /* Verify global parameter setup */
55 FUNCTION check_global_setup
56     RETURN BOOLEAN;
57 
58 /* Return true if some rows stopped because of uncosted transactions */
59 FUNCTION bounds_uncosted
60     RETURN BOOLEAN;
61 
62 
63 /*  Print the MMT bounds before which the OPI discrete orgs stopped, and the
64     reason for stopping
65 */
66 PROCEDURE print_opi_org_bounds;
67 
68 
69 END opi_dbi_common_mod_init_pkg;