DBA Data[Home] [Help]

APPS.FA_CALC_DEPRN_BASIS1_PKG dependencies on FA_CACHE_PKG

Line 342: if NOT fa_cache_pkg.fazcbcs(X_book => rule_in.book_type_code,

338:
339:
340:
341: if (rule_in.mrc_sob_type_code = 'R') then
342: if NOT fa_cache_pkg.fazcbcs(X_book => rule_in.book_type_code,
343: p_log_level_rec => p_log_level_rec) then
344: raise faxcdb_err;
345: end if;
346: else

Line 348: if NOT fa_cache_pkg.fazcbc(X_book => rule_in.book_type_code,

344: raise faxcdb_err;
345: end if;
346: else
347: -- call the cache for the primary transaction book
348: if NOT fa_cache_pkg.fazcbc(X_book => rule_in.book_type_code,
349: p_log_level_rec => p_log_level_rec) then
350: raise faxcdb_err;
351: end if;
352: end if;

Line 357: if (fa_cache_pkg.fazcdbr_record.deprn_basis_rule_id is null) or

353: -----------------------------------------------------------
354: -- Call Depreciable Basis rules
355: -----------------------------------------------------------
356:
357: if (fa_cache_pkg.fazcdbr_record.deprn_basis_rule_id is null) or
358: ((g_rule_in.method_code <> fa_cache_pkg.fazccmt_record.method_code) or
359: (nvl(g_rule_in.life_in_months, -99) <> nvl(fa_cache_pkg.fazccmt_record.life_in_months, -99))) then
360: if fa_cache_pkg.fazccmt(g_rule_in.method_code, g_rule_in.life_in_months) then
361: if p_log_level_rec.statement_level then

Line 358: ((g_rule_in.method_code <> fa_cache_pkg.fazccmt_record.method_code) or

354: -- Call Depreciable Basis rules
355: -----------------------------------------------------------
356:
357: if (fa_cache_pkg.fazcdbr_record.deprn_basis_rule_id is null) or
358: ((g_rule_in.method_code <> fa_cache_pkg.fazccmt_record.method_code) or
359: (nvl(g_rule_in.life_in_months, -99) <> nvl(fa_cache_pkg.fazccmt_record.life_in_months, -99))) then
360: if fa_cache_pkg.fazccmt(g_rule_in.method_code, g_rule_in.life_in_months) then
361: if p_log_level_rec.statement_level then
362: fa_debug_pkg.add(fname=>'faxcdb',

Line 359: (nvl(g_rule_in.life_in_months, -99) <> nvl(fa_cache_pkg.fazccmt_record.life_in_months, -99))) then

355: -----------------------------------------------------------
356:
357: if (fa_cache_pkg.fazcdbr_record.deprn_basis_rule_id is null) or
358: ((g_rule_in.method_code <> fa_cache_pkg.fazccmt_record.method_code) or
359: (nvl(g_rule_in.life_in_months, -99) <> nvl(fa_cache_pkg.fazccmt_record.life_in_months, -99))) then
360: if fa_cache_pkg.fazccmt(g_rule_in.method_code, g_rule_in.life_in_months) then
361: if p_log_level_rec.statement_level then
362: fa_debug_pkg.add(fname=>'faxcdb',
363: element=>'fazcdbr',

Line 360: if fa_cache_pkg.fazccmt(g_rule_in.method_code, g_rule_in.life_in_months) then

356:
357: if (fa_cache_pkg.fazcdbr_record.deprn_basis_rule_id is null) or
358: ((g_rule_in.method_code <> fa_cache_pkg.fazccmt_record.method_code) or
359: (nvl(g_rule_in.life_in_months, -99) <> nvl(fa_cache_pkg.fazccmt_record.life_in_months, -99))) then
360: if fa_cache_pkg.fazccmt(g_rule_in.method_code, g_rule_in.life_in_months) then
361: if p_log_level_rec.statement_level then
362: fa_debug_pkg.add(fname=>'faxcdb',
363: element=>'fazcdbr',
364: value=> 'Called'

Line 372: rule_id := fa_cache_pkg.fazcdbr_record.deprn_basis_rule_id;

368: end if;
369:
370:
371: -- Set flags for depreciable basis rule setup
372: rule_id := fa_cache_pkg.fazcdbr_record.deprn_basis_rule_id;
373: l_rule_name := fa_cache_pkg.fazcdbr_record.rule_name;
374: l_period_update_flag := fa_cache_pkg.fazcdrd_record.period_update_flag;
375: l_subtract_ytd_flag := fa_cache_pkg.fazcdrd_record.subtract_ytd_flag;
376: if p_log_level_rec.statement_level then

Line 373: l_rule_name := fa_cache_pkg.fazcdbr_record.rule_name;

369:
370:
371: -- Set flags for depreciable basis rule setup
372: rule_id := fa_cache_pkg.fazcdbr_record.deprn_basis_rule_id;
373: l_rule_name := fa_cache_pkg.fazcdbr_record.rule_name;
374: l_period_update_flag := fa_cache_pkg.fazcdrd_record.period_update_flag;
375: l_subtract_ytd_flag := fa_cache_pkg.fazcdrd_record.subtract_ytd_flag;
376: if p_log_level_rec.statement_level then
377: fa_debug_pkg.add(fname =>'faxcdb',

Line 374: l_period_update_flag := fa_cache_pkg.fazcdrd_record.period_update_flag;

370:
371: -- Set flags for depreciable basis rule setup
372: rule_id := fa_cache_pkg.fazcdbr_record.deprn_basis_rule_id;
373: l_rule_name := fa_cache_pkg.fazcdbr_record.rule_name;
374: l_period_update_flag := fa_cache_pkg.fazcdrd_record.period_update_flag;
375: l_subtract_ytd_flag := fa_cache_pkg.fazcdrd_record.subtract_ytd_flag;
376: if p_log_level_rec.statement_level then
377: fa_debug_pkg.add(fname =>'faxcdb',
378: element =>'rule_id',

Line 375: l_subtract_ytd_flag := fa_cache_pkg.fazcdrd_record.subtract_ytd_flag;

371: -- Set flags for depreciable basis rule setup
372: rule_id := fa_cache_pkg.fazcdbr_record.deprn_basis_rule_id;
373: l_rule_name := fa_cache_pkg.fazcdbr_record.rule_name;
374: l_period_update_flag := fa_cache_pkg.fazcdrd_record.period_update_flag;
375: l_subtract_ytd_flag := fa_cache_pkg.fazcdrd_record.subtract_ytd_flag;
376: if p_log_level_rec.statement_level then
377: fa_debug_pkg.add(fname =>'faxcdb',
378: element =>'rule_id',
379: value => rule_id

Line 649: if nvl(fa_cache_pkg.fazccmt_record.guarantee_rate_method_flag,'NO') = 'YES' then

645: g_rule_out.new_formula_factor := nvl(g_rule_in.old_formula_factor,1);
646: else
647:
648: -- Bug 6665510: FP: Japan Tax Reform Project (Start)
649: if nvl(fa_cache_pkg.fazccmt_record.guarantee_rate_method_flag,'NO') = 'YES' then
650:
651: select bk.deprn_method_code, bk.salvage_value, bk.cost -- bug 6378955 (added salvage value)
652: into l_old_method_code, l_old_salvage_value, l_old_cost -- l_old_cost added for Japan overlapped
653: from FA_BOOKS bk

Line 727: AND nvl(fa_cache_pkg.fazccmt_record.guarantee_rate_method_flag,'NO') <> 'YES'

723: -- Bug 6665510: FP: Japan Tax Reform Project
724: -- (Changed below if bcoz Reinstament was causing change in Adjusted_cost,
725: -- and here adjusted_cost change is restrcited for guarantee methods)
726: if (g_rule_in.method_type = 'FORMULA' and g_rule_in.calc_basis ='NBV'
727: AND nvl(fa_cache_pkg.fazccmt_record.guarantee_rate_method_flag,'NO') <> 'YES'
728: ) then
729: -- Bug 5212364
730: if (g_rule_in.current_rsv <> 0) then
731: g_rule_out.new_adjusted_cost :=

Line 840: fa_debug_pkg.add('faxcdb', '+++ Guarantee Flag : ', fa_cache_pkg.fazccmt_record.guarantee_rate_method_flag,

836:
837: elsif g_rule_in.calc_basis = 'NBV' then
838: -- Bug 6665510: FP: Japan Tax Reform Project (Start)
839: if p_log_level_rec.statement_level then
840: fa_debug_pkg.add('faxcdb', '+++ Guarantee Flag : ', fa_cache_pkg.fazccmt_record.guarantee_rate_method_flag,
841: p_log_level_rec);
842: end if;
843:
844: if nvl(fa_cache_pkg.fazccmt_record.guarantee_rate_method_flag,'NO') = 'YES' then

Line 844: if nvl(fa_cache_pkg.fazccmt_record.guarantee_rate_method_flag,'NO') = 'YES' then

840: fa_debug_pkg.add('faxcdb', '+++ Guarantee Flag : ', fa_cache_pkg.fazccmt_record.guarantee_rate_method_flag,
841: p_log_level_rec);
842: end if;
843:
844: if nvl(fa_cache_pkg.fazccmt_record.guarantee_rate_method_flag,'NO') = 'YES' then
845:
846: if p_log_level_rec.statement_level then
847: fa_debug_pkg.add('faxcdb', '+++ Inside Guarantee Logic', 'YES', p_log_level_rec);
848: end if;

Line 858: fa_debug_pkg.add('faxcdb', '+++ Revised Rate : ', fa_cache_pkg.fazcfor_record.revised_rate, p_log_level_rec);

854: AND book_type_code = g_rule_in.book_type_code
855: AND date_ineffective is null;
856:
857: if p_log_level_rec.statement_level then
858: fa_debug_pkg.add('faxcdb', '+++ Revised Rate : ', fa_cache_pkg.fazcfor_record.revised_rate, p_log_level_rec);
859: fa_debug_pkg.add('faxcdb', '+++ FA_Books.Rate : ', l_rate_in_use, p_log_level_rec);
860: fa_debug_pkg.add('faxcdb', '+++ FA_Books.deprn_method : ', l_old_method_code, p_log_level_rec);
861: end if;
862:

Line 866: elsif fa_cache_pkg.fazcfor_record.revised_rate = l_rate_in_use then

862:
863: -- Added if clause for bug fix 6780736
864: if g_rule_in.method_code <> l_old_method_code then
865: g_rule_out.new_adjusted_cost := g_rule_in.recoverable_cost - g_rule_in.current_total_rsv;
866: elsif fa_cache_pkg.fazcfor_record.revised_rate = l_rate_in_use then
867: Null; -- Dont change adjusted cost.
868: else
869: if p_log_level_rec.statement_level then
870: fa_debug_pkg.add('faxcdb', '+++ ORIGINAL RATE', 'YES', p_log_level_rec);

Line 954: and dp.fiscal_year = fa_cache_pkg.fazcbc_record.current_fiscal_year;

950: and bks.date_ineffective is null
951: and dp.book_type_code = l_book_type_code
952: and bks.date_effective between
953: dp.period_open_date and nvl(dp.period_close_date, sysdate)
954: and dp.fiscal_year = fa_cache_pkg.fazcbc_record.current_fiscal_year;
955:
956: IF (l_last_trx_count =0) THEN
957: g_rule_out.new_adjusted_cost := g_rule_in.recoverable_cost - g_rule_in.eofy_reserve;
958: ELSE

Line 986: and fa_cache_pkg.fazccmt_record.rate_source_rule = fa_std_types.FAD_RSR_FLAT

982: -- Bug 7174365 Modified If condition to unchange adjusted cost for flat rate cost basis method.
983: IF
984: g_rule_in.amortization_start_date is null or
985: (g_rule_in.amortization_start_date is not null
986: and fa_cache_pkg.fazccmt_record.rate_source_rule = fa_std_types.FAD_RSR_FLAT
987: and fa_cache_pkg.fazccmt_record.deprn_basis_rule = fa_std_types.FAD_DBR_COST)
988: THEN
989: g_rule_out.new_adjusted_cost := g_rule_in.old_adjusted_cost;
990: g_rule_in.use_old_adj_cost_flag :='Y';

Line 987: and fa_cache_pkg.fazccmt_record.deprn_basis_rule = fa_std_types.FAD_DBR_COST)

983: IF
984: g_rule_in.amortization_start_date is null or
985: (g_rule_in.amortization_start_date is not null
986: and fa_cache_pkg.fazccmt_record.rate_source_rule = fa_std_types.FAD_RSR_FLAT
987: and fa_cache_pkg.fazccmt_record.deprn_basis_rule = fa_std_types.FAD_DBR_COST)
988: THEN
989: g_rule_out.new_adjusted_cost := g_rule_in.old_adjusted_cost;
990: g_rule_in.use_old_adj_cost_flag :='Y';
991:

Line 1022: 'BEGIN '||fa_cache_pkg.fazcdbr_record.program_name||';

1018: -- Call Depreciable Basis Rule
1019: ------------------------------------------------------------
1020:
1021: l_rule_formula :=
1022: 'BEGIN '||fa_cache_pkg.fazcdbr_record.program_name||';
1023:
1024: exception
1025: when others then
1026: fa_srvr_msg.add_sql_error

Line 1027: (calling_fn => '''||fa_cache_pkg.fazcdbr_record.program_name||'''

1023:
1024: exception
1025: when others then
1026: fa_srvr_msg.add_sql_error
1027: (calling_fn => '''||fa_cache_pkg.fazcdbr_record.program_name||'''
1028: ,p_log_level_rec => Null);
1029: raise;
1030: END;';
1031: --removed p_log_level_rec and added null for bug 6345540

Line 1042: if (fa_cache_pkg.fazcdbr_record.program_name is not null) then

1038:
1039: -----------------------------------------------
1040: -- Run formula
1041: -----------------------------------------------
1042: if (fa_cache_pkg.fazcdbr_record.program_name is not null) then
1043: if p_log_level_rec.statement_level then
1044:
1045: fa_debug_pkg.add(fname=>'faxcdb',
1046: element=>'Rule Name before rule logic',

Line 1704: if not fa_cache_pkg.fazcct(fa_cache_pkg.fazcbc_record.deprn_calendar) then

1700: OPEN C_GET_DATE;
1701: Fetch C_GET_DATE into l_fy_start_date,l_fy_end_date, l_fy_mid_year_date,
1702: l_cp_start_date,l_cp_end_date;
1703: if(C_GET_DATE%NOTFOUND)then
1704: if not fa_cache_pkg.fazcct(fa_cache_pkg.fazcbc_record.deprn_calendar) then
1705: raise no_mid_date_err;
1706: end if;
1707: --bug fix 5005592
1708: begin

Line 1723: AND fy.fiscal_year_name = fa_cache_pkg.fazcbc_record.fiscal_year_name

1719: FROM fa_calendar_periods cp,
1720: fa_fiscal_year fy,
1721: fa_calendar_types cal_ty
1722: WHERE fy.fiscal_year = floor(p_period_counter/cal_ty.NUMBER_PER_FISCAL_YEAR)
1723: AND fy.fiscal_year_name = fa_cache_pkg.fazcbc_record.fiscal_year_name
1724: AND cal_ty.calendar_type = fa_cache_pkg.fazcbc_record.deprn_calendar
1725: AND cp.calendar_type = cal_ty.calendar_type
1726: AND cp.start_date BETWEEN fy.start_date AND fy.end_date
1727: AND cp.end_date BETWEEN fy.start_date AND fy.end_date

Line 1724: AND cal_ty.calendar_type = fa_cache_pkg.fazcbc_record.deprn_calendar

1720: fa_fiscal_year fy,
1721: fa_calendar_types cal_ty
1722: WHERE fy.fiscal_year = floor(p_period_counter/cal_ty.NUMBER_PER_FISCAL_YEAR)
1723: AND fy.fiscal_year_name = fa_cache_pkg.fazcbc_record.fiscal_year_name
1724: AND cal_ty.calendar_type = fa_cache_pkg.fazcbc_record.deprn_calendar
1725: AND cp.calendar_type = cal_ty.calendar_type
1726: AND cp.start_date BETWEEN fy.start_date AND fy.end_date
1727: AND cp.end_date BETWEEN fy.start_date AND fy.end_date
1728: and period_num = mod(p_period_counter,cal_ty.NUMBER_PER_FISCAL_YEAR);

Line 1869: if not fa_cache_pkg.fazcct(fa_cache_pkg.fazcbc_record.deprn_calendar) then

1865: OPEN C_GET_DATE_M;
1866: Fetch C_GET_DATE_M into l_fy_start_date,l_fy_end_date, l_fy_mid_year_date,
1867: l_cp_start_date,l_cp_end_date;
1868: if(C_GET_DATE_M%NOTFOUND)then
1869: if not fa_cache_pkg.fazcct(fa_cache_pkg.fazcbc_record.deprn_calendar) then
1870: raise no_mid_date_err;
1871: end if;
1872: --bug fix 5005592
1873: begin

Line 1888: AND fy.fiscal_year_name = fa_cache_pkg.fazcbc_record.fiscal_year_name

1884: FROM fa_calendar_periods cp,
1885: fa_fiscal_year fy,
1886: fa_calendar_types cal_ty
1887: WHERE fy.fiscal_year = floor(p_period_counter/cal_ty.NUMBER_PER_FISCAL_YEAR)
1888: AND fy.fiscal_year_name = fa_cache_pkg.fazcbc_record.fiscal_year_name
1889: AND cal_ty.calendar_type = fa_cache_pkg.fazcbc_record.deprn_calendar
1890: AND cp.calendar_type = cal_ty.calendar_type
1891: AND cp.start_date BETWEEN fy.start_date AND fy.end_date
1892: AND cp.end_date BETWEEN fy.start_date AND fy.end_date

Line 1889: AND cal_ty.calendar_type = fa_cache_pkg.fazcbc_record.deprn_calendar

1885: fa_fiscal_year fy,
1886: fa_calendar_types cal_ty
1887: WHERE fy.fiscal_year = floor(p_period_counter/cal_ty.NUMBER_PER_FISCAL_YEAR)
1888: AND fy.fiscal_year_name = fa_cache_pkg.fazcbc_record.fiscal_year_name
1889: AND cal_ty.calendar_type = fa_cache_pkg.fazcbc_record.deprn_calendar
1890: AND cp.calendar_type = cal_ty.calendar_type
1891: AND cp.start_date BETWEEN fy.start_date AND fy.end_date
1892: AND cp.end_date BETWEEN fy.start_date AND fy.end_date
1893: and period_num = mod(p_period_counter,cal_ty.NUMBER_PER_FISCAL_YEAR);

Line 2491: and CP.CALENDAR_TYPE = fa_cache_pkg.fazcbc_record.deprn_calendar

2487: where TH.TRANSACTION_HEADER_ID = BK1.TRANSACTION_HEADER_ID_OUT(+)
2488: and TH.TRANSACTION_HEADER_ID = BK2.TRANSACTION_HEADER_ID_IN
2489: and BK2.BOOK_TYPE_CODE = p_book_type_code
2490: and TH.TRANSACTION_DATE_ENTERED <= CP.END_DATE
2491: and CP.CALENDAR_TYPE = fa_cache_pkg.fazcbc_record.deprn_calendar
2492: and CP.CALENDAR_TYPE = fa_cache_pkg.fazcct_record.calendar_type
2493: and CP.END_DATE <= l_fy_end_date
2494: and CP.END_DATE >= l_fy_start_date
2495: and CP.PERIOD_NUM = p_period_num

Line 2492: and CP.CALENDAR_TYPE = fa_cache_pkg.fazcct_record.calendar_type

2488: and TH.TRANSACTION_HEADER_ID = BK2.TRANSACTION_HEADER_ID_IN
2489: and BK2.BOOK_TYPE_CODE = p_book_type_code
2490: and TH.TRANSACTION_DATE_ENTERED <= CP.END_DATE
2491: and CP.CALENDAR_TYPE = fa_cache_pkg.fazcbc_record.deprn_calendar
2492: and CP.CALENDAR_TYPE = fa_cache_pkg.fazcct_record.calendar_type
2493: and CP.END_DATE <= l_fy_end_date
2494: and CP.END_DATE >= l_fy_start_date
2495: and CP.PERIOD_NUM = p_period_num
2496: and exists (select TH.ASSET_ID

Line 2513: and CP.CALENDAR_TYPE = fa_cache_pkg.fazcbc_record.deprn_calendar

2509: and BK.TRANSACTION_HEADER_ID_IN =TH.TRANSACTION_HEADER_ID
2510: and BK.ASSET_ID= TH.ASSET_ID
2511: and BK.BOOK_TYPE_CODE= TH.BOOK_TYPE_CODE
2512: and TH.TRANSACTION_DATE_ENTERED <= CP.END_DATE
2513: and CP.CALENDAR_TYPE = fa_cache_pkg.fazcbc_record.deprn_calendar
2514: and CP.CALENDAR_TYPE = fa_cache_pkg.fazcct_record.calendar_type
2515: and CP.END_DATE <= l_fy_end_date
2516: and CP.END_DATE >= l_fy_start_date
2517: and CP.PERIOD_NUM = p_period_num

Line 2514: and CP.CALENDAR_TYPE = fa_cache_pkg.fazcct_record.calendar_type

2510: and BK.ASSET_ID= TH.ASSET_ID
2511: and BK.BOOK_TYPE_CODE= TH.BOOK_TYPE_CODE
2512: and TH.TRANSACTION_DATE_ENTERED <= CP.END_DATE
2513: and CP.CALENDAR_TYPE = fa_cache_pkg.fazcbc_record.deprn_calendar
2514: and CP.CALENDAR_TYPE = fa_cache_pkg.fazcct_record.calendar_type
2515: and CP.END_DATE <= l_fy_end_date
2516: and CP.END_DATE >= l_fy_start_date
2517: and CP.PERIOD_NUM = p_period_num
2518: )

Line 2538: and CP.CALENDAR_TYPE = fa_cache_pkg.fazcbcs_record.deprn_calendar

2534: where TH.TRANSACTION_HEADER_ID = BK1.TRANSACTION_HEADER_ID_OUT(+)
2535: and TH.TRANSACTION_HEADER_ID = BK2.TRANSACTION_HEADER_ID_IN
2536: and BK2.BOOK_TYPE_CODE = p_book_type_code
2537: and TH.TRANSACTION_DATE_ENTERED <= CP.END_DATE
2538: and CP.CALENDAR_TYPE = fa_cache_pkg.fazcbcs_record.deprn_calendar
2539: and CP.CALENDAR_TYPE = fa_cache_pkg.fazcct_record.calendar_type
2540: and CP.END_DATE <= l_fy_end_date
2541: and CP.END_DATE >= l_fy_start_date
2542: and CP.PERIOD_NUM = p_period_num

Line 2539: and CP.CALENDAR_TYPE = fa_cache_pkg.fazcct_record.calendar_type

2535: and TH.TRANSACTION_HEADER_ID = BK2.TRANSACTION_HEADER_ID_IN
2536: and BK2.BOOK_TYPE_CODE = p_book_type_code
2537: and TH.TRANSACTION_DATE_ENTERED <= CP.END_DATE
2538: and CP.CALENDAR_TYPE = fa_cache_pkg.fazcbcs_record.deprn_calendar
2539: and CP.CALENDAR_TYPE = fa_cache_pkg.fazcct_record.calendar_type
2540: and CP.END_DATE <= l_fy_end_date
2541: and CP.END_DATE >= l_fy_start_date
2542: and CP.PERIOD_NUM = p_period_num
2543: and exists (select TH.ASSET_ID

Line 2561: and CP.CALENDAR_TYPE = fa_cache_pkg.fazcbcs_record.deprn_calendar

2557: and BK.TRANSACTION_HEADER_ID_IN =TH.TRANSACTION_HEADER_ID
2558: and BK.ASSET_ID= TH.ASSET_ID
2559: and BK.BOOK_TYPE_CODE= TH.BOOK_TYPE_CODE
2560: and TH.TRANSACTION_DATE_ENTERED <= CP.END_DATE
2561: and CP.CALENDAR_TYPE = fa_cache_pkg.fazcbcs_record.deprn_calendar
2562: and CP.CALENDAR_TYPE = fa_cache_pkg.fazcct_record.calendar_type
2563: and CP.END_DATE <= l_fy_end_date
2564: and CP.END_DATE >= l_fy_start_date
2565: and CP.PERIOD_NUM = p_period_num

Line 2562: and CP.CALENDAR_TYPE = fa_cache_pkg.fazcct_record.calendar_type

2558: and BK.ASSET_ID= TH.ASSET_ID
2559: and BK.BOOK_TYPE_CODE= TH.BOOK_TYPE_CODE
2560: and TH.TRANSACTION_DATE_ENTERED <= CP.END_DATE
2561: and CP.CALENDAR_TYPE = fa_cache_pkg.fazcbcs_record.deprn_calendar
2562: and CP.CALENDAR_TYPE = fa_cache_pkg.fazcct_record.calendar_type
2563: and CP.END_DATE <= l_fy_end_date
2564: and CP.END_DATE >= l_fy_start_date
2565: and CP.PERIOD_NUM = p_period_num
2566: )

Line 2574: where fiscal_year_name = fa_cache_pkg.fazcbc_record.fiscal_year_name

2570: cursor c_find_fy is
2571: select start_date
2572: , end_date
2573: from fa_fiscal_year
2574: where fiscal_year_name = fa_cache_pkg.fazcbc_record.fiscal_year_name
2575: and fiscal_year = p_fiscal_year;
2576:
2577:
2578: -- Get period close date

Line 2637: if (not(fa_cache_pkg.fazccmt_record.rate_source_rule = fa_std_types.FAD_RSR_CALC or

2633: begin
2634:
2635: -- Skipping entire process for straight line and flat-cost PE and User rec cost deprn basis
2636: -- rule because it is unnecessary.
2637: if (not(fa_cache_pkg.fazccmt_record.rate_source_rule = fa_std_types.FAD_RSR_CALC or
2638: (fa_cache_pkg.fazccmt_record.rate_source_rule = fa_std_types.FAD_RSR_FLAT and
2639: fa_cache_pkg.fazccmt_record.deprn_basis_rule = fa_std_types.FAD_DBR_COST and
2640: fa_cache_pkg.fazcdbr_record.rule_name in ('PERIOD END BALANCE', 'USE RECOVERABLE COST'))
2641: )) then

Line 2638: (fa_cache_pkg.fazccmt_record.rate_source_rule = fa_std_types.FAD_RSR_FLAT and

2634:
2635: -- Skipping entire process for straight line and flat-cost PE and User rec cost deprn basis
2636: -- rule because it is unnecessary.
2637: if (not(fa_cache_pkg.fazccmt_record.rate_source_rule = fa_std_types.FAD_RSR_CALC or
2638: (fa_cache_pkg.fazccmt_record.rate_source_rule = fa_std_types.FAD_RSR_FLAT and
2639: fa_cache_pkg.fazccmt_record.deprn_basis_rule = fa_std_types.FAD_DBR_COST and
2640: fa_cache_pkg.fazcdbr_record.rule_name in ('PERIOD END BALANCE', 'USE RECOVERABLE COST'))
2641: )) then
2642:

Line 2639: fa_cache_pkg.fazccmt_record.deprn_basis_rule = fa_std_types.FAD_DBR_COST and

2635: -- Skipping entire process for straight line and flat-cost PE and User rec cost deprn basis
2636: -- rule because it is unnecessary.
2637: if (not(fa_cache_pkg.fazccmt_record.rate_source_rule = fa_std_types.FAD_RSR_CALC or
2638: (fa_cache_pkg.fazccmt_record.rate_source_rule = fa_std_types.FAD_RSR_FLAT and
2639: fa_cache_pkg.fazccmt_record.deprn_basis_rule = fa_std_types.FAD_DBR_COST and
2640: fa_cache_pkg.fazcdbr_record.rule_name in ('PERIOD END BALANCE', 'USE RECOVERABLE COST'))
2641: )) then
2642:
2643: -------------------------------------------------

Line 2640: fa_cache_pkg.fazcdbr_record.rule_name in ('PERIOD END BALANCE', 'USE RECOVERABLE COST'))

2636: -- rule because it is unnecessary.
2637: if (not(fa_cache_pkg.fazccmt_record.rate_source_rule = fa_std_types.FAD_RSR_CALC or
2638: (fa_cache_pkg.fazccmt_record.rate_source_rule = fa_std_types.FAD_RSR_FLAT and
2639: fa_cache_pkg.fazccmt_record.deprn_basis_rule = fa_std_types.FAD_DBR_COST and
2640: fa_cache_pkg.fazcdbr_record.rule_name in ('PERIOD END BALANCE', 'USE RECOVERABLE COST'))
2641: )) then
2642:
2643: -------------------------------------------------
2644: -- Treate this transaction's

Line 2710: if not fa_cache_pkg.fazcct(fa_cache_pkg.fazcbc_record.deprn_calendar,

2706: end if;
2707: end if;
2708:
2709: -- bug4943259: Added function calls fazcct fazcfy
2710: if not fa_cache_pkg.fazcct(fa_cache_pkg.fazcbc_record.deprn_calendar,
2711: p_log_level_rec) then
2712: raise grc_err;
2713: end if;
2714:

Line 2715: if not fa_cache_pkg.fazcfy(fa_cache_pkg.fazcbc_record.fiscal_year_name,

2711: p_log_level_rec) then
2712: raise grc_err;
2713: end if;
2714:
2715: if not fa_cache_pkg.fazcfy(fa_cache_pkg.fazcbc_record.fiscal_year_name,
2716: p_fiscal_year,
2717: p_log_level_rec) then
2718: -- find out whether fazcfy returned false because of missing record or not.
2719: OPEN c_find_fy;

Line 2731: l_fy_start_date := fa_cache_pkg.fazcfy_record.start_date;

2727: CLOSE c_find_fy;
2728: raise grc_err;
2729: end if;
2730: else
2731: l_fy_start_date := fa_cache_pkg.fazcfy_record.start_date;
2732: l_fy_end_date := fa_cache_pkg.fazcfy_record.end_date;
2733: end if;
2734:
2735:

Line 2732: l_fy_end_date := fa_cache_pkg.fazcfy_record.end_date;

2728: raise grc_err;
2729: end if;
2730: else
2731: l_fy_start_date := fa_cache_pkg.fazcfy_record.start_date;
2732: l_fy_end_date := fa_cache_pkg.fazcfy_record.end_date;
2733: end if;
2734:
2735:
2736: if p_mrc_sob_type_code <>'R' then

Line 2949: if NOT fa_cache_pkg.fazcbcs(X_book => p_book_type_code,

2945: to_char(p_period_num));
2946: end if;
2947:
2948: if (p_mrc_sob_type_code = 'R') then
2949: if NOT fa_cache_pkg.fazcbcs(X_book => p_book_type_code,
2950: p_log_level_rec => p_log_level_rec) then
2951: raise l_get_eofy_eop_err;
2952: end if;
2953: else

Line 2955: if NOT fa_cache_pkg.fazcbc(X_book => p_book_type_code,

2951: raise l_get_eofy_eop_err;
2952: end if;
2953: else
2954: -- call the cache for the primary transaction book
2955: if NOT fa_cache_pkg.fazcbc(X_book => p_book_type_code,
2956: p_log_level_rec => p_log_level_rec) then
2957: raise l_get_eofy_eop_err;
2958: end if;
2959: end if;

Line 2965: if not fa_cache_pkg.fazcct(fa_cache_pkg.fazcbc_record.deprn_calendar) then

2961:
2962: if p_asset_type = 'GROUP' then
2963: if p_period_counter is null then
2964:
2965: if not fa_cache_pkg.fazcct(fa_cache_pkg.fazcbc_record.deprn_calendar) then
2966: raise l_get_eofy_eop_err;
2967: end if;
2968:
2969: l_period_counter := p_fiscal_year *

Line 2970: fa_cache_pkg.fazcct_record.NUMBER_PER_FISCAL_YEAR +

2966: raise l_get_eofy_eop_err;
2967: end if;
2968:
2969: l_period_counter := p_fiscal_year *
2970: fa_cache_pkg.fazcct_record.NUMBER_PER_FISCAL_YEAR +
2971: p_period_num;
2972:
2973: else
2974:

Line 3248: if (fa_cache_pkg.fazccmt_record.rate_source_rule is null) or

3244: tmp_method_code := p_asset_fin_rec_new.Deprn_Method_Code;
3245: tmp_life_in_months := p_asset_fin_rec_new.Life_In_Months;
3246: end if;
3247:
3248: if (fa_cache_pkg.fazccmt_record.rate_source_rule is null) or
3249: ((tmp_method_code <> fa_cache_pkg.fazccmt_record.method_code) or
3250: (nvl(tmp_life_in_months, -99) <> nvl(fa_cache_pkg.fazccmt_record.life_in_months, -99))) then
3251: if not fa_cache_pkg.fazccmt
3252: (X_method => tmp_method_code,

Line 3249: ((tmp_method_code <> fa_cache_pkg.fazccmt_record.method_code) or

3245: tmp_life_in_months := p_asset_fin_rec_new.Life_In_Months;
3246: end if;
3247:
3248: if (fa_cache_pkg.fazccmt_record.rate_source_rule is null) or
3249: ((tmp_method_code <> fa_cache_pkg.fazccmt_record.method_code) or
3250: (nvl(tmp_life_in_months, -99) <> nvl(fa_cache_pkg.fazccmt_record.life_in_months, -99))) then
3251: if not fa_cache_pkg.fazccmt
3252: (X_method => tmp_method_code,
3253: X_life => tmp_life_in_months

Line 3250: (nvl(tmp_life_in_months, -99) <> nvl(fa_cache_pkg.fazccmt_record.life_in_months, -99))) then

3246: end if;
3247:
3248: if (fa_cache_pkg.fazccmt_record.rate_source_rule is null) or
3249: ((tmp_method_code <> fa_cache_pkg.fazccmt_record.method_code) or
3250: (nvl(tmp_life_in_months, -99) <> nvl(fa_cache_pkg.fazccmt_record.life_in_months, -99))) then
3251: if not fa_cache_pkg.fazccmt
3252: (X_method => tmp_method_code,
3253: X_life => tmp_life_in_months
3254: ,p_log_level_rec => p_log_level_rec) then

Line 3251: if not fa_cache_pkg.fazccmt

3247:
3248: if (fa_cache_pkg.fazccmt_record.rate_source_rule is null) or
3249: ((tmp_method_code <> fa_cache_pkg.fazccmt_record.method_code) or
3250: (nvl(tmp_life_in_months, -99) <> nvl(fa_cache_pkg.fazccmt_record.life_in_months, -99))) then
3251: if not fa_cache_pkg.fazccmt
3252: (X_method => tmp_method_code,
3253: X_life => tmp_life_in_months
3254: ,p_log_level_rec => p_log_level_rec) then
3255:

Line 3273: h_rule_in.method_id := fa_cache_pkg.fazccmt_record.method_id;

3269: h_rule_in.asset_type := nvl(p_dpr.asset_type, p_asset_type_rec.asset_type);
3270: h_rule_in.depreciate_flag := p_asset_fin_rec_new.depreciate_flag;
3271: h_rule_in.method_code := p_asset_fin_rec_new.deprn_method_code;
3272: h_rule_in.life_in_months := p_asset_fin_rec_new.life_in_months;
3273: h_rule_in.method_id := fa_cache_pkg.fazccmt_record.method_id;
3274: h_rule_in.method_type := fa_cache_pkg.fazccmt_record.rate_source_rule;
3275: h_rule_in.calc_basis := fa_cache_pkg.fazccmt_record.deprn_basis_rule;
3276: h_rule_in.adjustment_amount := nvl(p_asset_fin_rec_new.cost,0)
3277: - nvl(p_asset_fin_rec_old.cost,0);

Line 3274: h_rule_in.method_type := fa_cache_pkg.fazccmt_record.rate_source_rule;

3270: h_rule_in.depreciate_flag := p_asset_fin_rec_new.depreciate_flag;
3271: h_rule_in.method_code := p_asset_fin_rec_new.deprn_method_code;
3272: h_rule_in.life_in_months := p_asset_fin_rec_new.life_in_months;
3273: h_rule_in.method_id := fa_cache_pkg.fazccmt_record.method_id;
3274: h_rule_in.method_type := fa_cache_pkg.fazccmt_record.rate_source_rule;
3275: h_rule_in.calc_basis := fa_cache_pkg.fazccmt_record.deprn_basis_rule;
3276: h_rule_in.adjustment_amount := nvl(p_asset_fin_rec_new.cost,0)
3277: - nvl(p_asset_fin_rec_old.cost,0);
3278: h_rule_in.transaction_flag := null;

Line 3275: h_rule_in.calc_basis := fa_cache_pkg.fazccmt_record.deprn_basis_rule;

3271: h_rule_in.method_code := p_asset_fin_rec_new.deprn_method_code;
3272: h_rule_in.life_in_months := p_asset_fin_rec_new.life_in_months;
3273: h_rule_in.method_id := fa_cache_pkg.fazccmt_record.method_id;
3274: h_rule_in.method_type := fa_cache_pkg.fazccmt_record.rate_source_rule;
3275: h_rule_in.calc_basis := fa_cache_pkg.fazccmt_record.deprn_basis_rule;
3276: h_rule_in.adjustment_amount := nvl(p_asset_fin_rec_new.cost,0)
3277: - nvl(p_asset_fin_rec_old.cost,0);
3278: h_rule_in.transaction_flag := null;
3279: h_rule_in.cost := nvl(p_asset_fin_rec_new.cost,0);

Line 3443: if (fa_cache_pkg.fazcdbr_record.rule_name in ('PERIOD END AVERAGE', 'BEGINNING PERIOD',

3439: -- eofy and eop amounts are necessary only if deprn basis rules are following
3440: -- need eop amounts: 'PERIOD END AVERAGE', 'BEGINNING PERIOD'
3441: -- need eofy amounts: 'YEAR TO DATE AVERAGE', 'YEAR END BALANCE WITH HALF YEAR RULE'
3442: --
3443: if (fa_cache_pkg.fazcdbr_record.rule_name in ('PERIOD END AVERAGE', 'BEGINNING PERIOD',
3444: 'YEAR TO DATE AVERAGE',
3445: 'YEAR END BALANCE WITH HALF YEAR RULE',
3446: 'YEAR TO DATE AVERAGE WITH HALF YEAR RULE')) then
3447: fa_debug_pkg.add(l_calling_fn, 'eofy_rec', p_eofy_recoverable_cost

Line 3494: end if; -- (fa_cache_pkg.fazcdbr_record.rule_name in (....

3490: h_rule_in.eofy_recoverable_cost := 0;
3491: h_rule_in.eofy_salvage_value := 0;
3492: h_rule_in.eop_recoverable_cost := 0;
3493: h_rule_in.eop_salvage_value := 0;
3494: end if; -- (fa_cache_pkg.fazcdbr_record.rule_name in (....
3495:
3496: --------------------------------------------
3497: -- Set 0 to the end of fiscal year
3498: -- and end of period recoverable cost

Line 4343: and fa_cache_pkg.fazcdbr_record.rule_name in

4339: begin
4340:
4341: -- Validate recognize_gain_loss='Y'
4342: if g_rule_in.recognize_gain_loss='Y'
4343: and fa_cache_pkg.fazcdbr_record.rule_name in
4344: ('YEAR END BALANCE','YEAR END BALANCE WITH POSITIVE REDUCTION AMOUNT',
4345: 'YEAR END BALANCE WITH HALF YEAR RULE')
4346: then
4347: if g_log_level_rec.statement_level then

Line 4360: and (fa_cache_pkg.fazcdbr_record.rule_name in

4356: end if;
4357:
4358: -- Validate recognize_gain_loss='N'
4359: if g_rule_in.recognize_gain_loss='N'
4360: and (fa_cache_pkg.fazcdbr_record.rule_name in
4361: ('FLAT RATE EXTENSION',
4362: 'USE FISCAL YEAR BEGINNING BASIS')
4363: or (fa_cache_pkg.fazcdbr_record.rule_name = 'YEAR TO DATE AVERAGE'
4364: and g_rule_in.calc_basis = 'NBV')

Line 4363: or (fa_cache_pkg.fazcdbr_record.rule_name = 'YEAR TO DATE AVERAGE'

4359: if g_rule_in.recognize_gain_loss='N'
4360: and (fa_cache_pkg.fazcdbr_record.rule_name in
4361: ('FLAT RATE EXTENSION',
4362: 'USE FISCAL YEAR BEGINNING BASIS')
4363: or (fa_cache_pkg.fazcdbr_record.rule_name = 'YEAR TO DATE AVERAGE'
4364: and g_rule_in.calc_basis = 'NBV')
4365: )
4366: then
4367: if g_log_level_rec.statement_level then