DBA Data[Home] [Help]

APPS.BSC_MO_INDICATOR_PKG dependencies on BSC_KPI_DATA_TABLES

Line 181: -- P1 4148992 for query configured in bsc_kpi_data_tables

177: raise;
178:
179: END;
180:
181: -- P1 4148992 for query configured in bsc_kpi_data_tables
182: --
183: PROCEDURE find_join_betweens_levels(p_key IN BSC_METADATA_OPTIMIZER_PKG.clsKeyField,
184: p_zmv_key IN BSC_METADATA_OPTIMIZER_PKG.clsKeyField,
185: p_dimensions IN BSC_METADATA_OPTIMIZER_PKG.tab_tab_clsLevels,

Line 1205: DELETE FROM BSC_KPI_DATA_TABLES WHERE INDICATOR = Indicator.code AND DIM_SET_ID = Configuration;

1201: Configuration := colConfigurationes(j);
1202:
1203: If Indicator.Share_Flag = 2 And (Not IsFilteredIndicator(Indicator.Code, Configuration))
1204: And (Not IsFilteredIndicator(Indicator.source_indicator, Configuration))Then
1205: DELETE FROM BSC_KPI_DATA_TABLES WHERE INDICATOR = Indicator.code AND DIM_SET_ID = Configuration;
1206:
1207: --BSC-MV Note: include columns MV_NAME and PROJECTION_SOURCE, DATA_SOURCE, SQL_STMT
1208: -- and PROJECTION_DATA
1209: --3182722

Line 1210: l_stmt := 'INSERT INTO BSC_KPI_DATA_TABLES ( INDICATOR,PERIODICITY_ID,

1206:
1207: --BSC-MV Note: include columns MV_NAME and PROJECTION_SOURCE, DATA_SOURCE, SQL_STMT
1208: -- and PROJECTION_DATA
1209: --3182722
1210: l_stmt := 'INSERT INTO BSC_KPI_DATA_TABLES ( INDICATOR,PERIODICITY_ID,
1211: DIM_SET_ID, LEVEL_COMB, TABLE_NAME, FILTER_CONDITION ';
1212: If BSC_METADATA_OPTIMIZER_PKG.g_BSC_MV Then
1213: l_stmt := l_stmt ||', MV_NAME, PROJECTION_SOURCE , DATA_SOURCE , SQL_STMT , PROJECTION_DATA ';
1214: End If;

Line 1219: l_stmt := l_stmt ||' FROM BSC_KPI_DATA_TABLES WHERE INDICATOR = :3 AND DIM_SET_ID = :4';

1215: l_stmt := l_stmt ||' ) SELECT :1, PERIODICITY_ID, :2, LEVEL_COMB, TABLE_NAME, FILTER_CONDITION ';
1216: If BSC_METADATA_OPTIMIZER_PKG.g_BSC_MV Then
1217: l_stmt := l_stmt ||', MV_NAME, PROJECTION_SOURCE , DATA_SOURCE , SQL_STMT, PROJECTION_DATA ';
1218: End If;
1219: l_stmt := l_stmt ||' FROM BSC_KPI_DATA_TABLES WHERE INDICATOR = :3 AND DIM_SET_ID = :4';
1220:
1221: execute immediate l_stmt using Indicator.code, Configuration, Indicator.Source_Indicator, Configuration;
1222:
1223: End If;

Line 1547: UPDATE BSC_KPI_DATA_TABLES SET PROJECTION_SOURCE = 1,

1543: --Also configure iViewer to read projection from this table.
1544: If BSC_METADATA_OPTIMIZER_PKG.g_BSC_MV and l_table.impl_type=1 Then
1545: pt_name := GetProjectionTableName(l_table.name);
1546: l_Table.projectionTable := pt_name;
1547: UPDATE BSC_KPI_DATA_TABLES SET PROJECTION_SOURCE = 1,
1548: PROJECTION_DATA = pt_name
1549: WHERE INDICATOR = Indicator.code
1550: AND DIM_SET_ID = COnfiguration
1551: AND TABLE_NAME = l_table.name;

Line 1564: UPDATE BSC_KPI_DATA_TABLES SET PROJECTION_SOURCE = 1,

1560: --Also configure iViewer to read projection from this table.
1561: If BSC_METADATA_OPTIMIZER_PKG.g_BSC_MV and l_table.impl_type=1 Then
1562: pt_name := GetProjectionTableName(l_Table.Name);
1563: l_Table.projectionTable := pt_name;
1564: UPDATE BSC_KPI_DATA_TABLES SET PROJECTION_SOURCE = 1,
1565: PROJECTION_DATA = pt_name
1566: WHERE INDICATOR = Indicator.code
1567: AND DIM_SET_ID = COnfiguration
1568: AND TABLE_NAME = l_table.name;

Line 1724: TYPE tab_clsKPIData IS TABLE OF BSC_KPI_DATA_TABLES%ROWTYPE index by binary_integer;

1720: colConfigKpiMV BSC_METADATA_OPTIMIZER_PKG.tab_clsConfigKpiMV;
1721: l_counter NUMBER;
1722: first_periodicity_id NUMBEr := 0;
1723:
1724: TYPE tab_clsKPIData IS TABLE OF BSC_KPI_DATA_TABLES%ROWTYPE index by binary_integer;
1725: l_kpidata_record BSC_KPI_DATA_TABLES%ROWTYPE ;
1726: l_tbl_kpidata tab_clsKPIData;
1727: BEGIN
1728: bsc_mo_helper_pkg.writeTmp( ' ');

Line 1725: l_kpidata_record BSC_KPI_DATA_TABLES%ROWTYPE ;

1721: l_counter NUMBER;
1722: first_periodicity_id NUMBEr := 0;
1723:
1724: TYPE tab_clsKPIData IS TABLE OF BSC_KPI_DATA_TABLES%ROWTYPE index by binary_integer;
1725: l_kpidata_record BSC_KPI_DATA_TABLES%ROWTYPE ;
1726: l_tbl_kpidata tab_clsKPIData;
1727: BEGIN
1728: bsc_mo_helper_pkg.writeTmp( ' ');
1729: bsc_mo_helper_pkg.writeTmp( 'Inside deduce_and_configure_s_tables, Configuration = '||Configuration ||', forTargetLevel='

Line 1731: --Delete from BSC_KPI_DATA_TABLES the records for this indicator and configuration

1727: BEGIN
1728: bsc_mo_helper_pkg.writeTmp( ' ');
1729: bsc_mo_helper_pkg.writeTmp( 'Inside deduce_and_configure_s_tables, Configuration = '||Configuration ||', forTargetLevel='
1730: ||bsc_mo_helper_pkg.boolean_decode(forTargetLevel)||', System time is '||bsc_mo_helper_pkg.get_time, fnd_log.level_procedure, false);
1731: --Delete from BSC_KPI_DATA_TABLES the records for this indicator and configuration
1732: If Not forTargetLevel Then
1733: --The tables are not for targets
1734: DELETE FROM BSC_KPI_DATA_TABLES WHERE INDICATOR = Indicator.Code
1735: AND DIM_SET_ID = Configuration;

Line 1734: DELETE FROM BSC_KPI_DATA_TABLES WHERE INDICATOR = Indicator.Code

1730: ||bsc_mo_helper_pkg.boolean_decode(forTargetLevel)||', System time is '||bsc_mo_helper_pkg.get_time, fnd_log.level_procedure, false);
1731: --Delete from BSC_KPI_DATA_TABLES the records for this indicator and configuration
1732: If Not forTargetLevel Then
1733: --The tables are not for targets
1734: DELETE FROM BSC_KPI_DATA_TABLES WHERE INDICATOR = Indicator.Code
1735: AND DIM_SET_ID = Configuration;
1736: END IF;
1737: IF (colPeriodicities.count >0) THEN
1738: i := colPeriodicities.first;

Line 1915: --one by one in BSC_KPI_DATA_TABLES. For other periodicities

1911: If Not forTargetLevel Then
1912: --Tables for targets only are not read by the indicator
1913: If first_periodicity_id = 0 Then
1914: --This is the first periodicity. Only in this case we insert records
1915: --one by one in BSC_KPI_DATA_TABLES. For other periodicities
1916: --we will insert all the records with one query based on the records of this periodicity
1917: cond := null;
1918: k := basic_keys.first;
1919: LOOP

Line 1930: --EDW Note: For EDW KPIs we need to user the union view name in BSC_KPI_DATA_TABLES

1926: END IF;
1927: EXIT when k = basic_keys.last;
1928: k := basic_keys.next(k);
1929: END LOOP;
1930: --EDW Note: For EDW KPIs we need to user the union view name in BSC_KPI_DATA_TABLES
1931: If L_Table.EDW_Flag = 1 Then
1932: TableName := L_Table.Name || BSC_METADATA_OPTIMIZER_PKG.EDW_UNION_VIEW_EXT;
1933: Else
1934: TableName := L_Table.Name;

Line 1949: l_stmt := 'INSERT INTO BSC_KPI_DATA_TABLES (INDICATOR, PERIODICITY_ID, DIM_SET_ID, LEVEL_COMB,

1945: END IF;
1946: -- bug 3835059, we need to create sql stmts instead of mv if # of
1947: -- levels > BSC_METADATA_OPTIMIZER_PKG.MAX_ALLOWED_LEVELS
1948: colConfigKpiMV := GetColConfigKpiMV(Basica, TableLevel, p_dimension_families, colSummaryTables);
1949: l_stmt := 'INSERT INTO BSC_KPI_DATA_TABLES (INDICATOR, PERIODICITY_ID, DIM_SET_ID, LEVEL_COMB,
1950: TABLE_NAME, FILTER_CONDITION, MV_NAME, PROJECTION_SOURCE, DATA_SOURCE, SQL_STMT, PROJECTION_DATA)
1951: VALUES(:1, :2, :3, :4, :5, :6, :7, :8, :9, :10, :11)';
1952: l_counter := colConfigKpiMV.first;
1953: LOOP

Line 1987: /*INSERT INTO BSC_KPI_DATA_TABLES

1983: l_kpidata_record.DATA_SOURCE := null;
1984: l_kpidata_record.SQL_STMT := null;
1985: l_kpidata_record.PROJECTION_DATA := null;
1986: l_tbl_kpidata(l_tbl_kpidata.count+1):= l_kpidata_record;
1987: /*INSERT INTO BSC_KPI_DATA_TABLES
1988: (INDICATOR, PERIODICITY_ID, DIM_SET_ID,
1989: LEVEL_COMB, TABLE_NAME, FILTER_CONDITION)
1990: VALUES(Indicator.Code, L_Periodicity.Code, Configuration,
1991: nvl(Basica.levelConfig, '?'), TableName, cond);*/

Line 1999: INSERT INTO BSC_KPI_DATA_TABLES values l_tbl_kpidata(ii);

1995: EXIT WHEN j = colSummaryTables.last;
1996: j := colSummaryTables.next(j);
1997: END LOOP;
1998: FORALL ii IN 1..l_tbl_kpidata.count
1999: INSERT INTO BSC_KPI_DATA_TABLES values l_tbl_kpidata(ii);
2000: l_tbl_kpidata.delete;
2001: --BSC_KPI_DATA_TABLES was already configured for the fisrt periodicity
2002: --For this periodcity we can insert same set of records based on the first
2003: --periodicity so we avoid to do one by one again

Line 2001: --BSC_KPI_DATA_TABLES was already configured for the fisrt periodicity

1997: END LOOP;
1998: FORALL ii IN 1..l_tbl_kpidata.count
1999: INSERT INTO BSC_KPI_DATA_TABLES values l_tbl_kpidata(ii);
2000: l_tbl_kpidata.delete;
2001: --BSC_KPI_DATA_TABLES was already configured for the fisrt periodicity
2002: --For this periodcity we can insert same set of records based on the first
2003: --periodicity so we avoid to do one by one again
2004: --3135168
2005: If Not forTargetLevel Then

Line 2007: INSERT INTO BSC_KPI_DATA_TABLES

2003: --periodicity so we avoid to do one by one again
2004: --3135168
2005: If Not forTargetLevel Then
2006: If first_periodicity_id <> 0 Then
2007: INSERT INTO BSC_KPI_DATA_TABLES
2008: (INDICATOR, PERIODICITY_ID, DIM_SET_ID, LEVEL_COMB,
2009: TABLE_NAME, FILTER_CONDITION, MV_NAME, PROJECTION_SOURCE,
2010: DATA_SOURCE, SQL_STMT, PROJECTION_DATA)
2011: SELECT INDICATOR, L_Periodicity.Code , DIM_SET_ID, LEVEL_COMB,

Line 2014: FROM BSC_KPI_DATA_TABLES

2010: DATA_SOURCE, SQL_STMT, PROJECTION_DATA)
2011: SELECT INDICATOR, L_Periodicity.Code , DIM_SET_ID, LEVEL_COMB,
2012: SUBSTR(TABLE_NAME,1,INSTR(TABLE_NAME, '_', -1))||L_Periodicity.Code TABLE_NAME,
2013: FILTER_CONDITION, MV_NAME, PROJECTION_SOURCE, DATA_SOURCE, SQL_STMT, PROJECTION_DATA
2014: FROM BSC_KPI_DATA_TABLES
2015: WHERE INDICATOR = Indicator.Code
2016: AND PERIODICITY_ID = first_periodicity_id
2017: AND DIM_SET_ID = Configuration;
2018: Else

Line 4608: --I just wanted to re-configure BSC_KPI_DATA_TABLES and not re-configure loader.

4604: ConnectTargetTables(Indicator, Configuration);
4605: END IF;
4606: --BSC-MV Note: If the indicator is processed only for Summarization Level Change
4607: --(example for 2 to 3 or 3 to 2), I do not need the tables in gTablas.
4608: --I just wanted to re-configure BSC_KPI_DATA_TABLES and not re-configure loader.
4609: --Remove indicator tables from gTablas
4610: bLast := false;
4611: If (Indicator.Action_Flag = 0 Or Indicator.Action_Flag = 4) And bsc_metadata_optimizer_pkg.g_Sum_Level_Change = 2 Then
4612: i := bsc_metadata_optimizer_pkg.gTables.first;