DBA Data[Home] [Help]

APPS.FII_EA_CUMUL_EXP_TREND_PKG dependencies on FII_EA_UTIL_PKG

Line 129: fii_ea_util_pkg.reset_globals;

125: -- Procedure reset_globals to re-set the global variables to NULL.
126: -- It will set financial category type to 'OE', company parameter to 'All' and cost parameter to 'All'
127: -- financial category type is set to 'OE' since Cumulative Expense Trend is an expense related report
128:
129: fii_ea_util_pkg.reset_globals;
130:
131: -- Assigning budget/forecast profile value to local variables
132:
133: l_budget_time_unit := NVL(FND_PROFILE.Value( 'FII_BUDGET_TIME_UNIT' ),'P');

Line 145: fii_ea_util_pkg.get_parameters(p_page_parameter_tbl);

141:
142: -- Procedure get_parameters to assign values to different global variables
143: -- like as of date, period type, comparison type - being given by the user
144:
145: fii_ea_util_pkg.get_parameters(p_page_parameter_tbl);
146:
147: -- Following exercise is done to get the required label in the report table columns
148: -- For example : For Period Type = Month/Quarter, ViewBy Label should be Day
149: -- For Period Type = Year, ViewBy Label should be Month

Line 151: IF fii_ea_util_pkg.g_page_period_type = 'FII_TIME_ENT_YEAR' THEN

147: -- Following exercise is done to get the required label in the report table columns
148: -- For example : For Period Type = Month/Quarter, ViewBy Label should be Day
149: -- For Period Type = Year, ViewBy Label should be Month
150:
151: IF fii_ea_util_pkg.g_page_period_type = 'FII_TIME_ENT_YEAR' THEN
152: fii_ea_util_pkg.g_view_by := 'TIME+FII_TIME_ENT_PERIOD';
153: ELSE
154: fii_ea_util_pkg.g_view_by := 'TIME+FII_TIME_DAY';
155: END IF;

Line 152: fii_ea_util_pkg.g_view_by := 'TIME+FII_TIME_ENT_PERIOD';

148: -- For example : For Period Type = Month/Quarter, ViewBy Label should be Day
149: -- For Period Type = Year, ViewBy Label should be Month
150:
151: IF fii_ea_util_pkg.g_page_period_type = 'FII_TIME_ENT_YEAR' THEN
152: fii_ea_util_pkg.g_view_by := 'TIME+FII_TIME_ENT_PERIOD';
153: ELSE
154: fii_ea_util_pkg.g_view_by := 'TIME+FII_TIME_DAY';
155: END IF;
156:

Line 154: fii_ea_util_pkg.g_view_by := 'TIME+FII_TIME_DAY';

150:
151: IF fii_ea_util_pkg.g_page_period_type = 'FII_TIME_ENT_YEAR' THEN
152: fii_ea_util_pkg.g_view_by := 'TIME+FII_TIME_ENT_PERIOD';
153: ELSE
154: fii_ea_util_pkg.g_view_by := 'TIME+FII_TIME_DAY';
155: END IF;
156:
157: -- Typical values of l_budget_time_unit/l_forecast_time_unit are:
158: -- P -- Period level

Line 164: CASE fii_ea_util_pkg.g_page_period_type

160: -- Y -- Year level
161:
162: -- Initialisation of local variables for Budget calculations, which are used in the actual SQLs
163:
164: CASE fii_ea_util_pkg.g_page_period_type
165: WHEN 'FII_TIME_ENT_YEAR' THEN
166: l_budget_time_id := 'g.ent_year_id';
167: l_budget_table_name := 'fii_time_ent_year';
168: WHEN 'FII_TIME_ENT_QTR' THEN

Line 188: CASE fii_ea_util_pkg.g_page_period_type

184: END CASE;
185:
186: -- Initialisation of local variables for Forecast calculations, which are used in the actual SQLs
187:
188: CASE fii_ea_util_pkg.g_page_period_type
189: WHEN 'FII_TIME_ENT_YEAR' THEN
190: l_forecast_time_id := 'g.ent_year_id';
191: l_forecast_table_name := 'fii_time_ent_year';
192: WHEN 'FII_TIME_ENT_QTR' THEN

Line 217: IF fii_ea_util_pkg.g_company_id = 'All' THEN

213: -- implementing Company-CC security feature
214:
215: -- Obtaining all possible company-ids to which user has access
216:
217: IF fii_ea_util_pkg.g_company_id = 'All' THEN
218: l_company_security :=
219: ' AND f.company_id IN (SELECT company_id
220: FROM fii_company_grants
221: WHERE user_id = fnd_global.user_id

Line 222: AND report_region_code = '''||fii_ea_util_pkg.g_region_code||'''

218: l_company_security :=
219: ' AND f.company_id IN (SELECT company_id
220: FROM fii_company_grants
221: WHERE user_id = fnd_global.user_id
222: AND report_region_code = '''||fii_ea_util_pkg.g_region_code||'''
223: ) ';
224: l_comp_security_table := ',fii_company_grants com ';
225:
226: l_comp_security_days_clause := 'AND f.company_id = com.company_id

Line 228: AND com.report_region_code = '''||fii_ea_util_pkg.g_region_code||''' ';

224: l_comp_security_table := ',fii_company_grants com ';
225:
226: l_comp_security_days_clause := 'AND f.company_id = com.company_id
227: AND com.user_id = fnd_global.user_id
228: AND com.report_region_code = '''||fii_ea_util_pkg.g_region_code||''' ';
229: ELSE
230: l_company_security := ' AND f.company_id = :COMPANY_ID ' ;
231: l_comp_security_days_clause := ' AND f.company_id = :COMPANY_ID ' ;
232: END IF;

Line 236: IF fii_ea_util_pkg.g_cost_center_id = 'All' THEN

232: END IF;
233:
234: -- Obtaining all possible cost-center-ids to which user has access
235:
236: IF fii_ea_util_pkg.g_cost_center_id = 'All' THEN
237: l_cost_center_security :=
238: ' AND f.cost_center_id IN (SELECT cost_center_id
239: FROM fii_cost_center_grants
240: WHERE user_id = fnd_global.user_id

Line 241: AND report_region_code = '''||fii_ea_util_pkg.g_region_code||''' ) ';

237: l_cost_center_security :=
238: ' AND f.cost_center_id IN (SELECT cost_center_id
239: FROM fii_cost_center_grants
240: WHERE user_id = fnd_global.user_id
241: AND report_region_code = '''||fii_ea_util_pkg.g_region_code||''' ) ';
242:
243: l_cc_security_table := ' ,fii_cost_center_grants cc ';
244:
245: l_cc_security_days_clause := ' AND f.cost_center_id = cc.cost_center_id

Line 247: AND cc.report_region_code = '''||fii_ea_util_pkg.g_region_code||''' ';

243: l_cc_security_table := ' ,fii_cost_center_grants cc ';
244:
245: l_cc_security_days_clause := ' AND f.cost_center_id = cc.cost_center_id
246: AND cc.user_id = fnd_global.user_id
247: AND cc.report_region_code = '''||fii_ea_util_pkg.g_region_code||''' ';
248: ELSE
249: l_cost_center_security := ' AND f.cost_center_id = :COST_CENTER_ID ';
250: l_cc_security_days_clause := ' AND f.cost_center_id = :COST_CENTER_ID ';
251:

Line 265: IF fii_ea_util_pkg.g_page_period_type <> 'FII_TIME_ENT_YEAR' THEN

261: -- Reason 2: To show NULL for all the days which fall after As of Date chosen by the user
262: -- Variable, l_display_adjustment obtained here will be used in the main SQL to restrict data display
263: -- only till As of Date and to show NULL thereafter
264:
265: IF fii_ea_util_pkg.g_page_period_type <> 'FII_TIME_ENT_YEAR' THEN
266:
267: -- Following is done for reason 2 above
268:
269: IF fii_ea_util_pkg.g_page_period_type = 'FII_TIME_ENT_PERIOD' THEN

Line 269: IF fii_ea_util_pkg.g_page_period_type = 'FII_TIME_ENT_PERIOD' THEN

265: IF fii_ea_util_pkg.g_page_period_type <> 'FII_TIME_ENT_YEAR' THEN
266:
267: -- Following is done for reason 2 above
268:
269: IF fii_ea_util_pkg.g_page_period_type = 'FII_TIME_ENT_PERIOD' THEN
270: l_display_adjustment
271: := 'EXTRACT(DAY FROM :ASOF_DATE)';
272:
273: ELSE

Line 310: IF fii_ea_util_pkg.g_page_period_type = 'FII_TIME_ENT_YEAR' THEN

306:
307: -- Defining Budget/Forecast SQL's when Budget/Forecast profile option = 'N' and Period Type = Year
308:
309: IF (l_budget_forecast_profile = 'N') THEN
310: IF fii_ea_util_pkg.g_page_period_type = 'FII_TIME_ENT_YEAR' THEN
311: l_sql_budget_ver_year :=
312:
313: '( SELECT SUM(f.budget_g) FII_EA_BUDGET
314: FROM '||l_budget_table_name||' g -- Profile option = N, Period Type = Year

Line 315: ,fii_gl_trend_sum_mv'||fii_ea_util_pkg.g_curr_view||' f

311: l_sql_budget_ver_year :=
312:
313: '( SELECT SUM(f.budget_g) FII_EA_BUDGET
314: FROM '||l_budget_table_name||' g -- Profile option = N, Period Type = Year
315: ,fii_gl_trend_sum_mv'||fii_ea_util_pkg.g_curr_view||' f
316: WHERE f.time_id = '||l_budget_time_id||'
317: '||l_company_security||l_cost_center_security||'
318: AND top_node_fin_cat_type = ''OE''
319: AND NVL(f.budget_version_date,&BIS_CURRENT_ASOF_DATE) <= &BIS_CURRENT_ASOF_DATE

Line 332: ,fii_gl_trend_sum_mv'||fii_ea_util_pkg.g_curr_view||' f

328: l_sql_forecast_ver_year :=
329:
330: '( SELECT SUM( f.forecast_g) FII_EA_FORECAST
331: FROM '||l_forecast_table_name||' g -- Profile option = N, Period Type = Year
332: ,fii_gl_trend_sum_mv'||fii_ea_util_pkg.g_curr_view||' f
333: WHERE f.time_id = '||l_forecast_time_id||'
334: '||l_company_security||l_cost_center_security||'
335: AND top_node_fin_cat_type = ''OE''
336: AND NVL(f.budget_version_date,&BIS_CURRENT_ASOF_DATE) <= &BIS_CURRENT_ASOF_DATE

Line 355: ,fii_gl_trend_sum_mv'||fii_ea_util_pkg.g_curr_view||' f

351: l_sql_budget_ver_month_qtr :=
352:
353: '( SELECT SUM(f.budget_g) FII_EA_BUDGET
354: FROM '||l_budget_table_name||' g -- Profile option = N, Period Type = Month/Quarter
355: ,fii_gl_trend_sum_mv'||fii_ea_util_pkg.g_curr_view||' f
356: WHERE f.time_id = '||l_budget_time_id||'
357: '||l_company_security||l_cost_center_security||'
358: AND top_node_fin_cat_type = ''OE''
359: AND NVL(f.budget_version_date,&BIS_CURRENT_ASOF_DATE) <= &BIS_CURRENT_ASOF_DATE

Line 379: ,fii_gl_trend_sum_mv'||fii_ea_util_pkg.g_curr_view||' f

375: l_sql_forecast_ver_month_qtr :=
376:
377: '( SELECT SUM(f.forecast_g) FII_EA_FORECAST
378: FROM '||l_forecast_table_name||' g -- Profile option = N, Period Type = Month/Quarter
379: ,fii_gl_trend_sum_mv'||fii_ea_util_pkg.g_curr_view||' f
380: WHERE f.time_id = '||l_forecast_time_id||'
381: '||l_company_security||l_cost_center_security||'
382: AND top_node_fin_cat_type = ''OE''
383: AND NVL(f.budget_version_date,&BIS_CURRENT_ASOF_DATE) <= &BIS_CURRENT_ASOF_DATE

Line 436: ,fii_gl_trend_sum_mv'||fii_ea_util_pkg.g_curr_view||' f

432: ,time.name month_name
433: ,NULL FII_EA_XTD_CUMUL_EXP
434: ,f.actual_g FII_EA_PRIOR_XTD_CUMUL_EXP
435: FROM fii_time_ent_period time
436: ,fii_gl_trend_sum_mv'||fii_ea_util_pkg.g_curr_view||' f
437: WHERE f.time_id = time.ent_period_id
438: '||l_company_security||l_cost_center_security||' -- To restrict MV records based on
439: -- Company-CC security access
440: AND f.period_type_id = 32

Line 466: ,fii_gl_trend_sum_mv'||fii_ea_util_pkg.g_curr_view||' f

462: ,time.name month_name
463: ,f.actual_g FII_EA_XTD_CUMUL_EXP
464: ,NULL FII_EA_PRIOR_XTD_CUMUL_EXP
465: FROM fii_time_ent_period time
466: ,fii_gl_trend_sum_mv'||fii_ea_util_pkg.g_curr_view||' f
467: WHERE f.time_id = time.ent_period_id
468: '||l_company_security||l_cost_center_security||' -- To restrict MV records based on
469: -- Company-CC security access
470: AND f.period_type_id = 32

Line 496: ,fii_gl_trend_sum_mv'||fii_ea_util_pkg.g_curr_view||' f

492: SELECT time.name month_name
493: ,f.budget_g FII_EA_BUDGET
494: ,f.forecast_g FII_EA_FORECAST
495: FROM fii_time_ent_period time
496: ,fii_gl_trend_sum_mv'||fii_ea_util_pkg.g_curr_view||' f
497: WHERE f.time_id = time.ent_period_id
498: '||l_company_security||l_cost_center_security||' -- To restrict MV records based on
499: -- Company-CC security access
500: AND f.period_type_id = 32

Line 553: ,fii_gl_trend_sum_mv'||fii_ea_util_pkg.g_curr_view||' f

549: SELECT time.report_date REPORT_DATE
550: ,f.actual_g FII_EA_XTD_CUMUL_EXP
551: ,NULL FII_EA_PRIOR_XTD_CUMUL_EXP
552: FROM fii_time_day time
553: ,fii_gl_trend_sum_mv'||fii_ea_util_pkg.g_curr_view||' f
554: '||l_comp_security_table||'
555: '||l_cc_security_table||'
556: WHERE f.time_id = time.report_date_julian
557: '||l_comp_security_days_clause||'

Line 584: ,fii_gl_trend_sum_mv'||fii_ea_util_pkg.g_curr_view||' f

580: ( SELECT time.report_date REPORT_DATE
581: ,NULL FII_EA_XTD_CUMUL_EXP
582: ,f.actual_g FII_EA_PRIOR_XTD_CUMUL_EXP
583: FROM fii_time_day time
584: ,fii_gl_trend_sum_mv'||fii_ea_util_pkg.g_curr_view||' f
585: '||l_comp_security_table||'
586: '||l_cc_security_table||'
587: WHERE f.time_id = time.report_date_julian
588: '||l_comp_security_days_clause||'

Line 615: ,fii_gl_trend_sum_mv'||fii_ea_util_pkg.g_curr_view||' f

611: ,time.report_date - '||l_current_adjustment_days||'
612: DAYS2
613: FROM fii_time_ent_period g
614: ,fii_time_day time
615: ,fii_gl_trend_sum_mv'||fii_ea_util_pkg.g_curr_view||' f
616: '||l_comp_security_table||'
617: '||l_cc_security_table||'
618: WHERE f.time_id = g.ent_period_id
619: AND f.period_type_id = 32

Line 675: ,fii_gl_trend_sum_mv'||fii_ea_util_pkg.g_curr_view||' f

671: ,f.actual_g FII_EA_PRIOR_XTD_CUMUL_EXP
672: ,NULL FII_EA_BUDGET
673: ,NULL FII_EA_FORECAST
674: FROM fii_time_ent_period time
675: ,fii_gl_trend_sum_mv'||fii_ea_util_pkg.g_curr_view||' f
676: WHERE f.time_id = time.ent_period_id
677: '||l_company_security||l_cost_center_security||' -- To restrict MV records based on
678: -- Company-CC security access
679: AND f.period_type_id = 32

Line 702: ,fii_gl_trend_sum_mv'||fii_ea_util_pkg.g_curr_view||' f

698: ,NULL FII_EA_PRIOR_XTD_CUMUL_EXP
699: ,NULL FII_EA_BUDGET
700: ,NULL FII_EA_FORECAST
701: FROM fii_time_ent_period time
702: ,fii_gl_trend_sum_mv'||fii_ea_util_pkg.g_curr_view||' f
703: WHERE f.time_id = time.ent_period_id
704: '||l_company_security||l_cost_center_security||' -- To restrict MV records based on
705: -- Company-CC security access
706: AND f.period_type_id = 32

Line 775: ,fii_gl_trend_sum_mv'||fii_ea_util_pkg.g_curr_view||' f

771: ,NULL FII_EA_PRIOR_XTD_CUMUL_EXP
772: ,NULL FII_EA_BUDGET
773: ,NULL FII_EA_FORECAST
774: FROM fii_time_day time
775: ,fii_gl_trend_sum_mv'||fii_ea_util_pkg.g_curr_view||' f
776: '||l_comp_security_table||'
777: '||l_cc_security_table||'
778: WHERE f.time_id = time.report_date_julian
779: '||l_comp_security_days_clause||'

Line 814: ,fii_gl_trend_sum_mv'||fii_ea_util_pkg.g_curr_view||' f

810: ,f.actual_g FII_EA_PRIOR_XTD_CUMUL_EXP
811: ,NULL FII_EA_BUDGET
812: ,NULL FII_EA_FORECAST
813: FROM fii_time_day time
814: ,fii_gl_trend_sum_mv'||fii_ea_util_pkg.g_curr_view||' f
815: '||l_comp_security_table||'
816: '||l_cc_security_table||'
817: WHERE f.time_id = time.report_date_julian
818: '||l_comp_security_days_clause||'

Line 839: CASE fii_ea_util_pkg.g_page_period_type

835:
836: CASE l_budget_forecast_profile
837:
838: WHEN 'Y' THEN
839: CASE fii_ea_util_pkg.g_page_period_type
840:
841: WHEN 'FII_TIME_ENT_YEAR' THEN
842: l_actual_sql_statement := l_sql_statement1;
843:

Line 849: CASE fii_ea_util_pkg.g_page_period_type

845: l_actual_sql_statement := l_sql_statement2;
846: END CASE;
847:
848: ELSE
849: CASE fii_ea_util_pkg.g_page_period_type
850:
851: WHEN 'FII_TIME_ENT_YEAR' THEN
852: l_actual_sql_statement := l_sql_statement3;
853: ELSE

Line 861: fii_ea_util_pkg.bind_variable(

857:
858: -- Procedure bind_variable to pass the generated SQL statement and input/output variables to PMV
859: -- for generating Cumulative Expense Trend Report
860:
861: fii_ea_util_pkg.bind_variable(
862: p_sqlstmt => l_actual_sql_statement
863: ,p_page_parameter_tbl => p_page_parameter_tbl
864: ,p_sql_output => p_cumulative_expense_sql
865: ,p_bind_output_table => p_cumulative_expense_output