176: slask2 varchar2(100);
177:
178: begin
179:
180: --fa_rx_conc_mesg_pkg.log('IN HERE IN HERE 1');
181:
182: ret := TRUE;
183:
184: fa_whatif_deprn_pkg.t_request_id.delete;
232:
233: if h_check = 'NO' then
234: fnd_message.set_name('OFA','FA_BOOK_AMORTIZED_NOT_ALLOW');
235: h_mesg_str := fnd_message.get;
236: fa_rx_conc_mesg_pkg.log(h_mesg_str);
237:
238: x_return_status := 2;
239: return FALSE;
240: end if;
239: return FALSE;
240: end if;
241: end if;
242:
243: --fa_rx_conc_mesg_pkg.log('IN HERE IN HERE 2');
244:
245: -- SELECT VALUES THAT WILL REMAIN CONSTANT FOR ALL ASSETS:
246: -- FLEX STRUCTURES, PRECISION, LOGIN_ID
247:
306: close c_segs;
307:
308: -- end aggregate selects.
309:
310: --fa_rx_conc_mesg_pkg.log('IN HERE IN HERE 3');
311:
312: if (upper(X_hypo) in ('NO', 'N')) then
313:
314: h_count := 0;
384: fa_whatif_deprn_pkg.g_deprn.delete;
385: fnd_message.set_name('OFA','FA_WHATIF_ASSET_NORMAL_MODE');
386: fnd_message.set_token('ASSET_ID',X_assets(h_count),FALSE);
387: h_mesg_str := fnd_message.get;
388: fa_rx_conc_mesg_pkg.log(h_mesg_str);
389: return (FALSE);
390: end if;
391:
392:
445: fa_whatif_deprn_pkg.g_deprn.delete;
446: fnd_message.set_name('OFA','FA_WHATIF_ASSET_ADJ_MODE');
447: fnd_message.set_token('ASSET_ID',X_assets(h_count),FALSE);
448: h_mesg_str := fnd_message.get;
449: fa_rx_conc_mesg_pkg.log(h_mesg_str);
450: return (FALSE);
451: end if;
452: end if; -- (X_prorate_conv is not null) or
453:
479: fa_whatif_deprn_pkg.g_deprn.delete;
480: fnd_message.set_name('OFA','FA_WHATIF_ASSET_COMMIT');
481: fnd_message.set_token('ASSET_ID',X_assets(h_count),FALSE);
482: h_mesg_str := fnd_message.get;
483: fa_rx_conc_mesg_pkg.log(h_mesg_str);
484: return (FALSE);
485: end if;
486:
487: h_count := h_count + 1;
537:
538: else
539: -- HYPOTHETICAL ASSET
540:
541: --fa_rx_conc_mesg_pkg.log('IN HERE IN HERE');
542:
543: ret := fa_whatif_deprn_pkg.whatif_deprn_asset (
544: X_asset_id => 0,
545: X_mode => 'HYPOTHETICAL',
575: X_ytd_deprn => null,
576: X_ltd_prod => null,
577: x_return_status => x_return_status);
578:
579: --fa_rx_conc_mesg_pkg.log('OUT');
580:
581: if (ret = FALSE) then
582: x_return_status := 2;
583:
583:
584: fa_whatif_deprn_pkg.g_deprn.delete;
585: fnd_message.set_name('OFA','FA_WHATIF_ASSET_NORMAL_MODE');
586: h_mesg_str := fnd_message.get;
587: fa_rx_conc_mesg_pkg.log(h_mesg_str);
588: return (FALSE);
589: end if;
590:
591: if (X_adjusted_rate is not null) then
657:
658: exception when others then
659:
660: if SQLCODE <> 0 then
661: fa_Rx_conc_mesg_pkg.log(SQLERRM);
662: end if;
663:
664: fa_whatif_deprn_pkg.g_deprn.delete;
665: fnd_message.set_name('OFA',h_mesg_name);
666: if h_mesg_name like 'FA_WHATIF_ASSET%' then
667: fnd_message.set_token('ASSET_ID',X_assets(h_count),FALSE);
668: end if;
669: h_mesg_str := fnd_message.get;
670: fa_rx_conc_mesg_pkg.log(h_mesg_str);
671:
672: x_return_status := 2;
673: return FALSE;
674:
783: h_check := 1;
784: fnd_message.set_name('OFA','FA_WHATIF_ASSET_EXP_AMT');
785: fnd_message.set_token('ASSET_NUM',h_asset_number,FALSE);
786: h_mesg_str := fnd_message.get;
787: fa_rx_conc_mesg_pkg.log(h_mesg_str);
788: else
789: close c_check_amortized;
790: h_check := 0;
791: end if;
813: if h_check > 0 then
814: fnd_message.set_name('OFA','FA_WHATIF_ASSET_NO_DEPRN_YET');
815: fnd_message.set_token('ASSET_NUM',h_asset_number,FALSE);
816: h_mesg_str := fnd_message.get;
817: fa_rx_conc_mesg_pkg.log(h_mesg_str);
818: end if;
819: end if;
820:
821:
852:
853: exception when others then
854:
855: if SQLCODE <> 0 then
856: fa_Rx_conc_mesg_pkg.log(SQLERRM);
857: end if;
858: fnd_message.set_name('OFA',h_mesg_name);
859: if h_mesg_name like 'FA_WHATIF_ASSET%' then
860: fnd_message.set_token('ASSET_ID',h_asset_id,FALSE);
859: if h_mesg_name like 'FA_WHATIF_ASSET%' then
860: fnd_message.set_token('ASSET_ID',h_asset_id,FALSE);
861: end if;
862: h_mesg_str := fnd_message.get;
863: fa_rx_conc_mesg_pkg.log(h_mesg_str);
864:
865: x_return_status := 2;
866: return FALSE;
867: