49: ( p_api_version IN NUMBER
50: , p_Dimension_Level_Rec IN BIS_DIMENSION_LEVEL_PUB.Dimension_Level_Rec_Type
51: , x_Dim_Level_Value_Tbl OUT NOCOPY BIS_DIM_LEVEL_VALUE_PUB.Dim_Level_Value_Tbl_Type
52: , x_return_status OUT NOCOPY VARCHAR2
53: , x_error_Tbl OUT NOCOPY BIS_UTILITIES_PUB.Error_Tbl_Type
54: )
55: IS
56: BEGIN
57: NULL;
63: , p_Dimension_Level_Rec IN BIS_DIMENSION_LEVEL_PUB.Dimension_Level_Rec_Type
64: , p_Responsibility_Tbl IN BIS_RESPONSIBILITY_PVT.Responsibility_Tbl_Type
65: , x_Dim_Level_Value_Tbl OUT NOCOPY BIS_DIM_LEVEL_VALUE_PUB.Dim_Level_Value_Tbl_Type
66: , x_return_status OUT NOCOPY VARCHAR2
67: , x_error_Tbl OUT NOCOPY BIS_UTILITIES_PUB.Error_Tbl_Type
68: )
69: IS
70: --
71: l_view_name VARCHAR2(80);
242: , p_Dimension_Level_Rec IN BIS_DIMENSION_LEVEL_PUB.Dimension_Level_Rec_Type
243: , p_Responsibility_ID IN NUMBER
244: , x_Dim_Level_Value_Tbl OUT NOCOPY BIS_DIM_LEVEL_VALUE_PUB.Dim_Level_Value_Tbl_Type
245: , x_return_status OUT NOCOPY VARCHAR2
246: , x_error_Tbl OUT NOCOPY BIS_UTILITIES_PUB.Error_Tbl_Type
247: )
248: IS
249: --
250: l_view_name VARCHAR2(80);
398: ( p_api_version IN NUMBER
399: , p_Dimension_Level_Rec IN BIS_DIMENSION_LEVEL_PUB.Dimension_Level_Rec_Type
400: , x_Dim_Level_Value_Tbl OUT NOCOPY BIS_DIM_LEVEL_VALUE_PUB.Dim_Level_Value_Tbl_Type
401: , x_return_status OUT NOCOPY VARCHAR2
402: , x_error_Tbl OUT NOCOPY BIS_UTILITIES_PUB.Error_Tbl_Type
403: )
404: IS
405: --
406: l_view_name VARCHAR2(80);
538: ( p_api_version IN NUMBER
539: , p_Dimension_Level_Rec IN BIS_DIMENSION_LEVEL_PUB.Dimension_Level_Rec_Type
540: , x_Dim_Level_Value_Tbl OUT NOCOPY BIS_DIM_LEVEL_VALUE_PUB.Dim_Level_Value_Tbl_Type
541: , x_return_status OUT NOCOPY VARCHAR2
542: , x_error_Tbl OUT NOCOPY BIS_UTILITIES_PUB.Error_Tbl_Type
543: )
544: IS
545: --
546: l_view_name VARCHAR2(80);
682: , p_Dimension_Level_Rec IN BIS_DIMENSION_LEVEL_PUB.Dimension_Level_Rec_Type
683: , p_Dim_Level_Value_Rec IN BIS_DIM_LEVEL_VALUE_PUB.Dim_Level_Value_Rec_Type
684: , x_Dim_Level_Value_Tbl OUT NOCOPY BIS_DIM_LEVEL_VALUE_PUB.Dim_Level_Value_Tbl_Type
685: , x_return_status OUT NOCOPY VARCHAR2
686: , x_error_Tbl OUT NOCOPY BIS_UTILITIES_PUB.Error_Tbl_Type
687: )
688: IS
689: --
690: l_view_name VARCHAR2(80);
720: FROM BISBV_DIMENSION_LEVELS
721: WHERE DIMENSION_LEVEL_ID = p_Dimension_Level_Rec.Dimension_Level_ID;
722: --
723: IF(l_short_name <> 'TOTAL_TIME') THEN
724: IF (BIS_UTILITIES_PUB.is_time_dependent_on_org(p_time_lvl_short_name => l_short_name)
725: = BIS_UTILITIES_PUB.G_TIME_IS_DEPEN_ON_ORG) THEN --2684911
726: l_Org_Dept := TRUE;
727: l_select_stmt := 'SELECT '
728: || ' ID '
721: WHERE DIMENSION_LEVEL_ID = p_Dimension_Level_Rec.Dimension_Level_ID;
722: --
723: IF(l_short_name <> 'TOTAL_TIME') THEN
724: IF (BIS_UTILITIES_PUB.is_time_dependent_on_org(p_time_lvl_short_name => l_short_name)
725: = BIS_UTILITIES_PUB.G_TIME_IS_DEPEN_ON_ORG) THEN --2684911
726: l_Org_Dept := TRUE;
727: l_select_stmt := 'SELECT '
728: || ' ID '
729: || ', VALUE '
848: ( p_api_version IN NUMBER
849: , p_Dim_Level_Value_Tbl IN BIS_DIM_LEVEL_VALUE_PUB.Dim_Level_Value_Tbl_Type
850: , x_Dim_Level_Value_Tbl OUT NOCOPY BIS_DIM_LEVEL_VALUE_PUB.Dim_Level_Value_Tbl_Type
851: , x_return_status OUT NOCOPY VARCHAR2
852: , x_error_Tbl OUT NOCOPY BIS_UTILITIES_PUB.Error_Tbl_Type
853: )
854: IS
855: --
856: l_unique BOOLEAN;
909: , p_Dimension_Level_Rec IN BIS_DIMENSION_LEVEL_PUB.Dimension_Level_Rec_Type
910: , p_start_period IN VARCHAR2
911: , x_start_date OUT NOCOPY DATE
912: , x_return_status OUT NOCOPY VARCHAR2
913: , x_error_Tbl OUT NOCOPY BIS_UTILITIES_PUB.Error_Tbl_Type
914: )
915: IS
916: --
917: l_short_name VARCHAR2(30);
1013: , p_Dimension_Level_Rec IN BIS_DIMENSION_LEVEL_PUB.Dimension_Level_Rec_Type
1014: , p_end_period IN VARCHAR2
1015: , x_end_date OUT NOCOPY DATE
1016: , x_return_status OUT NOCOPY VARCHAR2
1017: , x_error_Tbl OUT NOCOPY BIS_UTILITIES_PUB.Error_Tbl_Type
1018: )
1019: IS
1020: --
1021: l_short_name VARCHAR2(30);
1116: ( p_api_version IN NUMBER
1117: , p_Dim_Level_Value_Rec IN BIS_DIM_LEVEL_VALUE_PUB.Dim_Level_Value_Rec_Type
1118: , x_Dim_Level_Value_Rec OUT NOCOPY BIS_DIM_LEVEL_VALUE_PUB.Dim_Level_Value_Rec_Type
1119: , x_return_status OUT NOCOPY VARCHAR2
1120: , x_error_Tbl OUT NOCOPY BIS_UTILITIES_PUB.Error_Tbl_Type
1121: )
1122: IS
1123: --
1124: l_view_name VARCHAR2(80);
1217: ( p_api_version IN NUMBER
1218: , p_Dim_Level_Value_Rec IN BIS_DIM_LEVEL_VALUE_PUB.Dim_Level_Value_Rec_Type
1219: , x_Dim_Level_Value_Rec OUT NOCOPY BIS_DIM_LEVEL_VALUE_PUB.Dim_Level_Value_Rec_Type
1220: , x_return_status OUT NOCOPY VARCHAR2
1221: , x_error_Tbl OUT NOCOPY BIS_UTILITIES_PUB.Error_Tbl_Type
1222: )
1223: IS
1224: --
1225: l_view_name VARCHAR2(80);
1321: , p_Org_Level_Value_Rec IN BIS_DIM_LEVEL_VALUE_PUB.Dim_Level_Value_Rec_Type
1322: , p_Dim_Level_Value_Rec IN BIS_DIM_LEVEL_VALUE_PUB.Dim_Level_Value_Rec_Type
1323: , x_Dim_Level_Value_Rec OUT NOCOPY BIS_DIM_LEVEL_VALUE_PUB.Dim_Level_Value_Rec_Type
1324: , x_return_status OUT NOCOPY VARCHAR2
1325: , x_error_Tbl OUT NOCOPY BIS_UTILITIES_PUB.Error_Tbl_Type
1326: )
1327: IS
1328: --
1329: l_view_name VARCHAR2(80);
1349: WHERE DIMENSION_LEVEL_ID = p_Dim_Level_Value_Rec.Dimension_Level_ID;
1350: --
1351: IF(l_short_name <> 'TOTAL_TIME') THEN
1352: --
1353: IF (BIS_UTILITIES_PUB.is_time_dependent_on_org(p_time_lvl_short_name => l_short_name)
1354: = BIS_UTILITIES_PUB.G_TIME_IS_DEPEN_ON_ORG) THEN --2684911
1355: l_select_stmt := 'SELECT '
1356: || ' PERIOD_SET_NAME '
1357: || ', PERIOD_NAME '
1350: --
1351: IF(l_short_name <> 'TOTAL_TIME') THEN
1352: --
1353: IF (BIS_UTILITIES_PUB.is_time_dependent_on_org(p_time_lvl_short_name => l_short_name)
1354: = BIS_UTILITIES_PUB.G_TIME_IS_DEPEN_ON_ORG) THEN --2684911
1355: l_select_stmt := 'SELECT '
1356: || ' PERIOD_SET_NAME '
1357: || ', PERIOD_NAME '
1358: || ' FROM '
1444: , p_Org_Level_Value_Rec IN BIS_DIM_LEVEL_VALUE_PUB.Dim_Level_Value_Rec_Type
1445: , p_Dim_Level_Value_Rec IN BIS_DIM_LEVEL_VALUE_PUB.Dim_Level_Value_Rec_Type
1446: , x_Dim_Level_Value_Rec OUT NOCOPY BIS_DIM_LEVEL_VALUE_PUB.Dim_Level_Value_Rec_Type
1447: , x_return_status OUT NOCOPY VARCHAR2
1448: , x_error_Tbl OUT NOCOPY BIS_UTILITIES_PUB.Error_Tbl_Type
1449: )
1450: IS
1451: --
1452: l_view_name VARCHAR2(80);
1472: WHERE DIMENSION_LEVEL_ID = p_Dim_Level_Value_Rec.Dimension_Level_ID;
1473: --
1474: IF(l_short_name <> 'TOTAL_TIME') THEN
1475: --
1476: IF (BIS_UTILITIES_PUB.is_time_dependent_on_org(p_time_lvl_short_name => l_short_name)
1477: = BIS_UTILITIES_PUB.G_TIME_IS_DEPEN_ON_ORG) THEN --2684911
1478: l_select_stmt := 'SELECT '
1479: || ' ID '
1480: || ', VALUE '
1473: --
1474: IF(l_short_name <> 'TOTAL_TIME') THEN
1475: --
1476: IF (BIS_UTILITIES_PUB.is_time_dependent_on_org(p_time_lvl_short_name => l_short_name)
1477: = BIS_UTILITIES_PUB.G_TIME_IS_DEPEN_ON_ORG) THEN --2684911
1478: l_select_stmt := 'SELECT '
1479: || ' ID '
1480: || ', VALUE '
1481: || ' FROM '
1571: , p_Dim_Level_Value_Rec IN BIS_DIM_LEVEL_VALUE_PUB.Dim_Level_Value_Rec_Type
1572: , p_set_of_books_id IN VARCHAR2 := NULL
1573: , x_Dim_Level_Value_Rec IN OUT NOCOPY BIS_DIM_LEVEL_VALUE_PUB.Dim_Level_Value_Rec_Type
1574: , x_return_status OUT NOCOPY VARCHAR2
1575: , x_error_Tbl OUT NOCOPY BIS_UTILITIES_PUB.Error_Tbl_Type
1576: )
1577: IS
1578: --
1579: l_view_name VARCHAR2(80);
1724: ( p_api_version IN NUMBER
1725: , p_Dim_Level_Value_Rec IN BIS_DIM_LEVEL_VALUE_PUB.Dim_Level_Value_Rec_Type
1726: , x_Dim_Level_Value_Rec OUT NOCOPY BIS_DIM_LEVEL_VALUE_PUB.Dim_Level_Value_Rec_Type
1727: , x_return_status OUT NOCOPY VARCHAR2
1728: , x_error_Tbl OUT NOCOPY BIS_UTILITIES_PUB.Error_Tbl_Type
1729: )
1730: IS
1731: --
1732: l_view_name VARCHAR2(80);
1832:
1833: l_sql VARCHAR2(32000);
1834: l_time_id VARCHAR2(32000) := NULL;
1835: l_dimension_level_rec BIS_DIMENSION_LEVEL_PUB.Dimension_Level_Rec_Type;
1836: l_error_Tbl BIS_UTILITIES_PUB.Error_Tbl_Type;
1837:
1838: l_view_name VARCHAR2(80);
1839: l_short_name VARCHAR2(30);
1840: l_name bis_levels_tl.name%TYPE;
1863:
1864:
1865: BEGIN
1866:
1867: BIS_UTILITIES_PUB.put_line(p_text =>'..... in Is_Current_Time_Period');
1868:
1869:
1870: BIS_PMF_GET_DIMLEVELS_PVT.Get_DimLevel_Values_Data
1871: (
1890: p_DimLevelId => l_level_id
1891: , p_DimLevelShortName => l_level_short_name -- l_level_name
1892: );
1893:
1894: BIS_UTILITIES_PUB.put_line(p_text =>' Source is '|| l_source );
1895:
1896:
1897: if ( l_source = 'OLTP' ) then
1898: bis_utilities_pvt.Get_Org_Info_Based_On_Source
1904: );
1905:
1906:
1907: if ( l_org_level_id is not null ) then
1908: BIS_UTILITIES_PUB.put_line(p_text => ' org level id = ' || l_org_level_id ) ;
1909: else
1910: BIS_UTILITIES_PUB.put_line(p_text => ' org level id = ' || l_org_level_id ) ;
1911: end if;
1912:
1906:
1907: if ( l_org_level_id is not null ) then
1908: BIS_UTILITIES_PUB.put_line(p_text => ' org level id = ' || l_org_level_id ) ;
1909: else
1910: BIS_UTILITIES_PUB.put_line(p_text => ' org level id = ' || l_org_level_id ) ;
1911: end if;
1912:
1913: elsif ( l_source = 'EDW') then
1914: l_org_level_id := p_org_level_id;
1914: l_org_level_id := p_org_level_id;
1915: l_org_level_short_name := p_org_level_short_name;
1916:
1917: elsif ( l_source <> 'EDW') then
1918: BIS_UTILITIES_PUB.put_line(p_text => ' ERROR: Is_Current_Time_Period : source can be only either OLTP or EDW ' );
1919: end if;
1920:
1921:
1922: bis_utilities_pvt.Get_Time_Level_Value_ID_Minus
1930: );
1931:
1932: x_current_time_id := l_time_id;
1933:
1934: if ( bis_utilities_pub.value_not_missing ( l_time_id ) = FND_API.G_TRUE )
1935: and ( bis_utilities_pub.value_not_null ( l_time_id ) = FND_API.G_TRUE )
1936: then
1937: BIS_UTILITIES_PUB.put_line(p_text => ' time id is ' || l_time_id );
1938: else
1931:
1932: x_current_time_id := l_time_id;
1933:
1934: if ( bis_utilities_pub.value_not_missing ( l_time_id ) = FND_API.G_TRUE )
1935: and ( bis_utilities_pub.value_not_null ( l_time_id ) = FND_API.G_TRUE )
1936: then
1937: BIS_UTILITIES_PUB.put_line(p_text => ' time id is ' || l_time_id );
1938: else
1939: BIS_UTILITIES_PUB.put_line(p_text => ' time id is NULL ' );
1933:
1934: if ( bis_utilities_pub.value_not_missing ( l_time_id ) = FND_API.G_TRUE )
1935: and ( bis_utilities_pub.value_not_null ( l_time_id ) = FND_API.G_TRUE )
1936: then
1937: BIS_UTILITIES_PUB.put_line(p_text => ' time id is ' || l_time_id );
1938: else
1939: BIS_UTILITIES_PUB.put_line(p_text => ' time id is NULL ' );
1940: end if;
1941:
1935: and ( bis_utilities_pub.value_not_null ( l_time_id ) = FND_API.G_TRUE )
1936: then
1937: BIS_UTILITIES_PUB.put_line(p_text => ' time id is ' || l_time_id );
1938: else
1939: BIS_UTILITIES_PUB.put_line(p_text => ' time id is NULL ' );
1940: end if;
1941:
1942: IF l_time_id = p_Dim_Level_Value_Rec.dimension_level_value_id THEN
1943: BIS_UTILITIES_PUB.put_line(p_text =>' is_current_time_period: This time level value id is in current period ');
1939: BIS_UTILITIES_PUB.put_line(p_text => ' time id is NULL ' );
1940: end if;
1941:
1942: IF l_time_id = p_Dim_Level_Value_Rec.dimension_level_value_id THEN
1943: BIS_UTILITIES_PUB.put_line(p_text =>' is_current_time_period: This time level value id is in current period ');
1944: RETURN true;
1945: ELSE
1946: BIS_UTILITIES_PUB.put_line(p_text =>' is_current_time_period: This time level value id is not in current period ');
1947: RETURN false;
1942: IF l_time_id = p_Dim_Level_Value_Rec.dimension_level_value_id THEN
1943: BIS_UTILITIES_PUB.put_line(p_text =>' is_current_time_period: This time level value id is in current period ');
1944: RETURN true;
1945: ELSE
1946: BIS_UTILITIES_PUB.put_line(p_text =>' is_current_time_period: This time level value id is not in current period ');
1947: RETURN false;
1948: END IF;
1949:
1950:
1949:
1950:
1951: EXCEPTION
1952: WHEN OTHERS THEN
1953: BIS_UTILITIES_PUB.put_line(p_text =>'exception at Is_Current_Time_Period 0500: '||sqlerrm);
1954:
1955: END Is_Current_Time_Period;
1956:
1957:
1968:
1969: l_sql VARCHAR2(32000);
1970: l_time_id VARCHAR2(32000) := NULL;
1971: l_dimension_level_rec BIS_DIMENSION_LEVEL_PUB.Dimension_Level_Rec_Type;
1972: l_error_Tbl BIS_UTILITIES_PUB.Error_Tbl_Type;
1973: --l_period_set_name VARCHAR2(32000);
1974:
1975: l_view_name VARCHAR2(80);
1976: l_short_name VARCHAR2(30);
2092: l_text := l_text || ' input time level value id = ' || p_Dim_Level_Value_Rec.Dimension_Level_value_ID ;
2093:
2094: l_text := l_text || ' ..... out NOCOPY of Is_Previous_Time_Period.';
2095:
2096: if ( bis_utilities_pub.value_not_missing ( l_time_id ) = FND_API.G_TRUE )
2097: and ( bis_utilities_pub.value_not_null ( l_time_id ) = FND_API.G_TRUE )
2098: then
2099: l_text := l_text || ' previous time id is ' || l_time_id ;
2100: else
2093:
2094: l_text := l_text || ' ..... out NOCOPY of Is_Previous_Time_Period.';
2095:
2096: if ( bis_utilities_pub.value_not_missing ( l_time_id ) = FND_API.G_TRUE )
2097: and ( bis_utilities_pub.value_not_null ( l_time_id ) = FND_API.G_TRUE )
2098: then
2099: l_text := l_text || ' previous time id is ' || l_time_id ;
2100: else
2101: l_text := l_text || ' previous time id is NULL ' ;
2101: l_text := l_text || ' previous time id is NULL ' ;
2102: end if;
2103:
2104:
2105: BIS_UTILITIES_PUB.put_line(p_text => l_text ) ;
2106:
2107:
2108: IF l_time_id = p_Dim_Level_Value_Rec.Dimension_Level_value_ID THEN
2109: BIS_UTILITIES_PUB.put_line(p_text =>' This time level value id is in previous period ');
2105: BIS_UTILITIES_PUB.put_line(p_text => l_text ) ;
2106:
2107:
2108: IF l_time_id = p_Dim_Level_Value_Rec.Dimension_Level_value_ID THEN
2109: BIS_UTILITIES_PUB.put_line(p_text =>' This time level value id is in previous period ');
2110: RETURN true;
2111: ELSE
2112: BIS_UTILITIES_PUB.put_line(p_text =>' This time level value id is not in previous period ');
2113: RETURN false;
2108: IF l_time_id = p_Dim_Level_Value_Rec.Dimension_Level_value_ID THEN
2109: BIS_UTILITIES_PUB.put_line(p_text =>' This time level value id is in previous period ');
2110: RETURN true;
2111: ELSE
2112: BIS_UTILITIES_PUB.put_line(p_text =>' This time level value id is not in previous period ');
2113: RETURN false;
2114: END IF;
2115:
2116:
2115:
2116:
2117: EXCEPTION
2118: WHEN OTHERS THEN
2119: BIS_UTILITIES_PUB.put_line(p_text =>'exception at Is_Previous_Time_Period: 0500 '||sqlerrm);
2120:
2121: END Is_Previous_Time_Period;
2122:
2123: --