DBA Data[Home] [Help]

APPS.FA_RETIREMENT_PVT dependencies on FA_TRANSACTION_HEADERS

Line 93: select fa_transaction_headers_s.nextval

89: and adjusted_cost <> 0
90: );
91:
92: CURSOR c_get_thid is
93: select fa_transaction_headers_s.nextval
94: from dual;
95:
96: CURSOR c_get_primary_thid is
97: select transaction_header_id

Line 98: from fa_transaction_headers

94: from dual;
95:
96: CURSOR c_get_primary_thid is
97: select transaction_header_id
98: from fa_transaction_headers
99: where asset_id = p_asset_fin_rec.group_asset_id
100: and book_type_code = p_asset_hdr_rec.book_type_code
101: and member_transaction_header_id = p_trans_rec.transaction_header_id;
102:

Line 105: l_transaction_header_id FA_TRANSACTION_HEADERS.TRANSACTION_HEADER_ID%TYPE;

101: and member_transaction_header_id = p_trans_rec.transaction_header_id;
102:
103: l_calling_fn VARCHAR2(100) := 'fa_retirement_pvt.do_retirement';
104:
105: l_transaction_header_id FA_TRANSACTION_HEADERS.TRANSACTION_HEADER_ID%TYPE;
106:
107: l_asset_desc_rec_m FA_API_TYPES.asset_desc_rec_type;
108: l_asset_desc_rec FA_API_TYPES.asset_desc_rec_type;
109: l_asset_type_rec FA_API_TYPES.asset_type_rec_type;

Line 700: from fa_transaction_headers

696: return boolean IS
697:
698: CURSOR c_get_thid IS
699: select transaction_header_id
700: from fa_transaction_headers
701: where asset_id = p_group_asset_id
702: and book_type_code = p_asset_hdr_rec.book_type_code
703: and member_transaction_header_id = p_transaction_header_id;
704:

Line 839: from fa_transaction_headers

835: and location_id = c_location_ccid;
836:
837: CURSOR c_get_transaction_type_code IS
838: select transaction_type_code
839: from fa_transaction_headers
840: where asset_id = p_asset_hdr_rec.asset_id
841: and book_type_code = p_asset_hdr_rec.book_type_code
842: and transaction_header_id = p_asset_retire_rec.detail_info.transaction_header_id_in;
843:

Line 849: select fa_transaction_headers_s.nextval

845: l_asset_hdr_rec FA_API_TYPES.asset_hdr_rec_type;
846:
847:
848: CURSOR c_get_thid is
849: select fa_transaction_headers_s.nextval
850: from dual;
851:
852: CURSOR c_get_primary_thid is
853: select transaction_header_id

Line 854: from fa_transaction_headers

850: from dual;
851:
852: CURSOR c_get_primary_thid is
853: select transaction_header_id
854: from fa_transaction_headers
855: where asset_id = p_asset_fin_rec.group_asset_id
856: and book_type_code = p_asset_hdr_rec.book_type_code
857: and member_transaction_header_id = p_trans_rec.transaction_header_id;
858:

Line 2373: FROM fa_transaction_headers

2369: CURSOR c_get_group_thid IS
2370: SELECT transaction_header_id,
2371: asset_id,
2372: date_effective
2373: FROM fa_transaction_headers
2374: WHERE member_transaction_header_id =
2375: p_asset_retire_rec.detail_info.transaction_header_id_in
2376: AND asset_id = p_asset_fin_rec.group_asset_id
2377: AND book_type_code = p_asset_hdr_rec.book_type_code;

Line 3137: select fa_transaction_headers_s.nextval

3133: p_calling_fn IN VARCHAR2, p_log_level_rec IN FA_API_TYPES.log_level_rec_type)
3134: return boolean IS
3135:
3136: CURSOR c_get_thid is
3137: select fa_transaction_headers_s.nextval
3138: from dual;
3139:
3140: CURSOR c_get_thx is
3141: select trx.transaction_date_entered

Line 3150: from fa_transaction_headers trx

3146: , trx.calling_interface
3147: , trx.mass_reference_id
3148: , nvl(trx.amortization_start_date, trx.transaction_date_entered)
3149: , trx.event_id
3150: from fa_transaction_headers trx
3151: where trx.transaction_header_id = p_ret.th_id_in;
3152:
3153: CURSOR c_member_exists IS
3154: select 'Y'

Line 3607: select fa_transaction_headers_s.nextval

3603: p_calling_fn IN VARCHAR2, p_log_level_rec IN FA_API_TYPES.log_level_rec_type)
3604: return boolean IS
3605:
3606: CURSOR c_get_thid is
3607: select fa_transaction_headers_s.nextval
3608: from dual;
3609:
3610: CURSOR c_get_thx is
3611: select trx.transaction_header_id

Line 3622: , fa_transaction_headers trx

3618: , trx.mass_reference_id
3619: , nvl(trx.amortization_start_date, trx.transaction_date_entered)
3620: , event_id
3621: from fa_retirements ret
3622: , fa_transaction_headers trx
3623: where ret.retirement_id = p_ret.retirement_id
3624: and ret.transaction_header_id_out = trx.transaction_header_id;
3625:
3626:

Line 3662: from fa_adjustments aj, fa_transaction_headers th

3658: -- gets expense that retirement created
3659: --+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
3660: CURSOR c_get_ret_info IS
3661: select sum(decode(debit_credit_flag, 'DR', -1, 1) * adjustment_amount)
3662: from fa_adjustments aj, fa_transaction_headers th
3663: where aj.source_type_code = 'RETIREMENT'
3664: and aj.adjustment_type = 'EXPENSE'
3665: and aj.asset_id = p_bk.group_asset_id
3666: and aj.book_type_code = p_ret.book

Line 3677: from fa_mc_adjustments aj, fa_transaction_headers th

3673: -- For MRC: gets expense that retirement created
3674: --+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
3675: CURSOR c_get_mc_ret_info IS
3676: select sum(decode(debit_credit_flag, 'DR', -1, 1) * adjustment_amount)
3677: from fa_mc_adjustments aj, fa_transaction_headers th
3678: where aj.source_type_code = 'RETIREMENT'
3679: and aj.adjustment_type = 'EXPENSE'
3680: and aj.asset_id = p_bk.group_asset_id
3681: and aj.book_type_code = p_ret.book

Line 4035: from fa_transaction_headers gth,

4031: and transaction_header_id_out is null;
4032:
4033: cursor c_max_ret_thid is
4034: select max(gth.transaction_header_id)
4035: from fa_transaction_headers gth,
4036: fa_transaction_headers mth,
4037: fa_retirements ret,
4038: fa_books bk
4039: where bk.group_asset_id = p_asset_id

Line 4036: fa_transaction_headers mth,

4032:
4033: cursor c_max_ret_thid is
4034: select max(gth.transaction_header_id)
4035: from fa_transaction_headers gth,
4036: fa_transaction_headers mth,
4037: fa_retirements ret,
4038: fa_books bk
4039: where bk.group_asset_id = p_asset_id
4040: and bk.book_type_code = p_book_type_code

Line 4061: from fa_transaction_headers gth,

4057: and set_of_books_id = p_set_of_books_id;
4058:
4059: cursor c_max_mc_ret_thid is
4060: select max(gth.transaction_header_id)
4061: from fa_transaction_headers gth,
4062: fa_transaction_headers mth,
4063: fa_mc_retirements ret,
4064: fa_mc_books bk
4065: where bk.group_asset_id = p_asset_id

Line 4062: fa_transaction_headers mth,

4058:
4059: cursor c_max_mc_ret_thid is
4060: select max(gth.transaction_header_id)
4061: from fa_transaction_headers gth,
4062: fa_transaction_headers mth,
4063: fa_mc_retirements ret,
4064: fa_mc_books bk
4065: where bk.group_asset_id = p_asset_id
4066: and bk.book_type_code = p_book_type_code

Line 4715: , fa_transaction_headers th

4711: , BK.ADJUSTED_COST ADJUSTED_COST
4712: , BK.RECOVERABLE_COST RECOVERABLE_COST
4713: FROM FA_BOOKS BK
4714: , FA_ADDITIONS_B AD
4715: , fa_transaction_headers th
4716: WHERE BK.BOOK_TYPE_CODE = p_asset_hdr_rec.book_type_code
4717: AND BK.TRANSACTION_HEADER_ID_OUT is null
4718: AND BK.GROUP_ASSET_ID = p_asset_hdr_rec.asset_id
4719: AND nvl(BK.CIP_COST, 0) = 0

Line 4732: , fa_transaction_headers th

4728: , BK.ADJUSTED_COST ADJUSTED_COST
4729: , BK.RECOVERABLE_COST RECOVERABLE_COST
4730: FROM FA_MC_BOOKS BK
4731: , FA_ADDITIONS_B AD
4732: , fa_transaction_headers th
4733: WHERE BK.BOOK_TYPE_CODE = p_asset_hdr_rec.book_type_code
4734: AND BK.TRANSACTION_HEADER_ID_OUT is null
4735: AND BK.GROUP_ASSET_ID = p_asset_hdr_rec.asset_id
4736: AND nvl(BK.CIP_COST, 0) = 0

Line 4900: FROM fa_transaction_headers fath

4896:
4897: /*Bug 9076882 - For MRC we need to retrieve the transaction headers from primary*/
4898: CURSOR C_THIDS (p_asset_id number,p_source_trans_id number) is
4899: SELECT min(transaction_header_id)
4900: FROM fa_transaction_headers fath
4901: WHERE fath.asset_id = p_asset_id
4902: and fath.source_transaction_header_id = p_source_trans_id;
4903:
4904: CURSOR C_THIDS_RECURR (p_asset_id number,p_source_trans_id number) is

Line 4906: FROM fa_transaction_headers fath

4902: and fath.source_transaction_header_id = p_source_trans_id;
4903:
4904: CURSOR C_THIDS_RECURR (p_asset_id number,p_source_trans_id number) is
4905: SELECT max(transaction_header_id)
4906: FROM fa_transaction_headers fath
4907: WHERE fath.asset_id = p_asset_id
4908: and fath.source_transaction_header_id = p_source_trans_id;
4909:
4910: CURSOR C_DIST_EXCESS IS

Line 4959: from fa_transaction_headers th -- member

4955: , ad.current_units
4956: , ad.asset_category_id
4957: , bk.adjusted_recoverable_cost
4958: , sum(aj.adjustment_amount)
4959: from fa_transaction_headers th -- member
4960: , fa_transaction_headers gth -- group
4961: , fa_adjustments aj
4962: , fa_deprn_periods dp
4963: , fa_additions_b ad

Line 4960: , fa_transaction_headers gth -- group

4956: , ad.asset_category_id
4957: , bk.adjusted_recoverable_cost
4958: , sum(aj.adjustment_amount)
4959: from fa_transaction_headers th -- member
4960: , fa_transaction_headers gth -- group
4961: , fa_adjustments aj
4962: , fa_deprn_periods dp
4963: , fa_additions_b ad
4964: , fa_books bk

Line 4997: from fa_transaction_headers th -- member

4993: , ad.current_units
4994: , ad.asset_category_id
4995: , bk.adjusted_recoverable_cost
4996: , sum(aj.adjustment_amount)
4997: from fa_transaction_headers th -- member
4998: , fa_transaction_headers gth -- group
4999: , fa_mc_adjustments aj
5000: , fa_mc_deprn_periods dp
5001: , fa_additions_b ad

Line 4998: , fa_transaction_headers gth -- group

4994: , ad.asset_category_id
4995: , bk.adjusted_recoverable_cost
4996: , sum(aj.adjustment_amount)
4997: from fa_transaction_headers th -- member
4998: , fa_transaction_headers gth -- group
4999: , fa_mc_adjustments aj
5000: , fa_mc_deprn_periods dp
5001: , fa_additions_b ad
5002: , fa_mc_books bk

Line 5052: from fa_transaction_headers th -- member

5048: reinstatement
5049: */
5050: CURSOR c_ret_adj_count IS
5051: select count(1)
5052: from fa_transaction_headers th -- member
5053: , fa_transaction_headers gth -- group
5054: , fa_adjustments aj
5055: where th.book_type_code = p_asset_hdr_rec.book_type_code
5056: and th.source_transaction_header_id = gth.transaction_header_id

Line 5053: , fa_transaction_headers gth -- group

5049: */
5050: CURSOR c_ret_adj_count IS
5051: select count(1)
5052: from fa_transaction_headers th -- member
5053: , fa_transaction_headers gth -- group
5054: , fa_adjustments aj
5055: where th.book_type_code = p_asset_hdr_rec.book_type_code
5056: and th.source_transaction_header_id = gth.transaction_header_id
5057: and gth.book_type_code = p_asset_hdr_rec.book_type_code

Line 5366: INSERT INTO FA_TRANSACTION_HEADERS(

5362: END IF;
5363:
5364: IF (p_mrc_sob_type_code <> 'R') THEN --Bug 9076882 No need insert transaction headers for MRC
5365: FORALL i in t_asset_id.first..l_th_count
5366: INSERT INTO FA_TRANSACTION_HEADERS(
5367: TRANSACTION_HEADER_ID
5368: , BOOK_TYPE_CODE
5369: , ASSET_ID
5370: , TRANSACTION_TYPE_CODE

Line 5384: FA_TRANSACTION_HEADERS_S.NEXTVAL

5380: , AMORTIZATION_START_DATE
5381: , CALLING_INTERFACE
5382: , MASS_TRANSACTION_ID
5383: ) VALUES (
5384: FA_TRANSACTION_HEADERS_S.NEXTVAL
5385: , p_asset_hdr_rec.book_type_code
5386: , t_asset_id(i)
5387: , 'ADJUSTMENT'
5388: , p_trans_rec.transaction_date_entered

Line 5591: select FA_TRANSACTION_HEADERS_S.NEXTVAL

5587:
5588: IF (p_mrc_sob_type_code <> 'R') THEN
5589: --Bug 9076882. No need to insert transaction for MRC.This is already fethced above using c_thids cursor
5590:
5591: select FA_TRANSACTION_HEADERS_S.NEXTVAL
5592: into t_thid(i)
5593: from dual;
5594:
5595: /* Insert record into fa_transaction_headers */

Line 5595: /* Insert record into fa_transaction_headers */

5591: select FA_TRANSACTION_HEADERS_S.NEXTVAL
5592: into t_thid(i)
5593: from dual;
5594:
5595: /* Insert record into fa_transaction_headers */
5596: INSERT INTO FA_TRANSACTION_HEADERS(
5597: TRANSACTION_HEADER_ID
5598: , BOOK_TYPE_CODE
5599: , ASSET_ID

Line 5596: INSERT INTO FA_TRANSACTION_HEADERS(

5592: into t_thid(i)
5593: from dual;
5594:
5595: /* Insert record into fa_transaction_headers */
5596: INSERT INTO FA_TRANSACTION_HEADERS(
5597: TRANSACTION_HEADER_ID
5598: , BOOK_TYPE_CODE
5599: , ASSET_ID
5600: , TRANSACTION_TYPE_CODE