DBA Data[Home] [Help]

APPS.FA_PROCESS_IMPAIRMENT_PKG dependencies on FA_IMPAIRMENTS

Line 157: from fa_impairments imp

153: /*Bug# 8394781- */
154: --Bug# 14595406 - Modified query
155: CURSOR c_get_asset_id(c_request_id number,c_period_counter number) IS
156: select asset_id
157: from fa_impairments imp
158: where imp.book_type_code = p_book_type_code
159: and imp.request_id = c_request_id
160: and imp.asset_id is not null
161: and not exists

Line 163: from fa_impairments imp2

159: and imp.request_id = c_request_id
160: and imp.asset_id is not null
161: and not exists
162: (select 'POSTED'
163: from fa_impairments imp2
164: where status = 'POSTED'
165: and ((imp2.asset_id = imp.asset_id) or
166: imp2.cash_generating_unit_id = (select cash_generating_unit_id
167: from fa_books fbs

Line 175: from fa_impairments imp,

171: and imp2.book_type_code = p_book_type_code
172: AND PERIOD_COUNTER_IMPAIRED = c_period_counter )
173: UNION
174: select bk.asset_id
175: from fa_impairments imp,
176: fa_books bk
177: where bk.cash_generating_unit_id = imp.cash_generating_unit_id
178: and bk.book_type_code = imp.book_type_code
179: and imp.book_type_code = p_book_type_code

Line 184: from fa_impairments imp2

180: and imp.request_id = c_request_id
181: and imp .asset_id is null
182: and not exists
183: (select 'POSTED'
184: from fa_impairments imp2
185: where status = 'POSTED'
186: and ((imp2.cash_generating_unit_id = imp.cash_generating_unit_id) or
187: imp2.asset_id in (select asset_id
188: from fa_books fbs

Line 299: UPDATE FA_IMPAIRMENTS imp

295: fa_debug_pkg.add(l_calling_fn,'l_period_rec.period_counter', l_period_rec.period_counter, p_log_level_rec => g_log_level_rec);
296: end if;
297:
298: if p_impairment_id is null then
299: UPDATE FA_IMPAIRMENTS imp
300: SET imp.STATUS = l_internal_mode
301: , imp.REQUEST_ID = l_request_id
302: , imp.PERIOD_COUNTER_IMPAIRED =
303: (select nvl(imp.PERIOD_COUNTER_IMPAIRED,

Line 321: UPDATE FA_IMPAIRMENTS imp

317: -- Bug#7264536 - To handle situation when impairment is posted simultaneously for different books
318: AND imp.BOOK_TYPE_CODE = p_book_type_code
319: RETURNING imp.IMPAIRMENT_DATE BULK COLLECT INTO t_imp_date;
320: else
321: UPDATE FA_IMPAIRMENTS imp
322: SET imp.STATUS = l_internal_mode
323: , imp.REQUEST_ID = l_request_id
324: , imp.PERIOD_COUNTER_IMPAIRED =
325: (select nvl(imp.PERIOD_COUNTER_IMPAIRED,

Line 347: FROM FA_IMPAIRMENTS

343: p_mode = 'PREVIEW' then
344:
345: SELECT count(IMPAIRMENT_ID)
346: INTO l_new_count
347: FROM FA_IMPAIRMENTS
348: WHERE STATUS = 'NEW'
349: AND REQUEST_ID is null;
350:
351: --

Line 640: FROM FA_IMPAIRMENTS imp2

636: , imp.PERIOD_COUNTER_IMPAIRED = l_period_rec.PERIOD_COUNTER
637: WHERE imp.SET_OF_BOOKS_ID = l_set_of_books_id
638: AND imp.BOOK_TYPE_CODE = p_book_type_code
639: AND exists (SELECT IMPAIRMENT_ID
640: FROM FA_IMPAIRMENTS imp2
641: WHERE imp2.status = l_internal_mode
642: AND imp2.BOOK_TYPE_CODE = p_book_type_code
643: AND imp2.impairment_id = IMP.IMPAIRMENT_ID);
644: end if;

Line 670: FROM FA_IMPAIRMENTS imp2

666: , imp.PERIOD_COUNTER_IMPAIRED = l_period_rec.PERIOD_COUNTER
667: WHERE imp.SET_OF_BOOKS_ID = l_set_of_books_id
668: AND imp.BOOK_TYPE_CODE = p_book_type_code
669: AND exists (SELECT IMPAIRMENT_ID
670: FROM FA_IMPAIRMENTS imp2
671: WHERE imp2.status = l_internal_mode
672: AND imp2.BOOK_TYPE_CODE = p_book_type_code
673: AND imp2.impairment_id = IMP.IMPAIRMENT_ID);
674: end if;

Line 859: UPDATE FA_IMPAIRMENTS

855: end if;
856:
857:
858:
859: UPDATE FA_IMPAIRMENTS
860: SET STATUS = l_internal_mode
861: WHERE REQUEST_ID = l_request_id
862: AND PERIOD_COUNTER_IMPAIRED = l_imp_period_rec.period_counter;
863:

Line 865: UPDATE FA_IMPAIRMENTS IMP

861: WHERE REQUEST_ID = l_request_id
862: AND PERIOD_COUNTER_IMPAIRED = l_imp_period_rec.period_counter;
863:
864: --Bug# 7045739 start to update status to Deprn Failed if multiple rows are uploaded.
865: UPDATE FA_IMPAIRMENTS IMP
866: SET STATUS='RUNNING DEPRN FAILED'
867: WHERE REQUEST_ID = l_request_id
868: AND EXISTS
869: (SELECT 'DUPLICATE RECORD'

Line 1290: from fa_impairments -- 8666930 changed to fa_impairments from fa_mc_impairments

1286: , SPLIT3_IMPAIR_CLASS
1287: , SPLIT3_REASON
1288: , SPLIT3_PERCENT
1289: , SPLIT3_LOSS_ACCT -- End of Bug 6666666
1290: from fa_impairments -- 8666930 changed to fa_impairments from fa_mc_impairments
1291: where request_id = p_request_id
1292: and book_type_code = p_book_type_code
1293: and PERIOD_COUNTER_IMPAIRED = p_period_rec.period_counter
1294: -- and set_of_books_id = p_set_of_books_id --8666930 commented

Line 1546: from fa_books bk , fa_impairments imp

1542: --Bug# 7292608 When updating uploaded impairment,existing row needs to be deleted first
1543: delete from fa_itf_impairments itmp
1544: where exists
1545: (select 'Uploaded impairment'
1546: from fa_books bk , fa_impairments imp
1547: where imp.book_type_code = p_book_type_code
1548: and imp.status = l_mode
1549: and imp.request_id = p_request_id
1550: and bk.book_type_code = p_book_type_code

Line 1631: , fa_impairments imp

1627: , imp.SPLIT3_REASON
1628: , imp.SPLIT3_PERCENT
1629: , imp.SPLIT3_LOSS_ACCT -- End of Bug 6666666
1630: from fa_books bk
1631: , fa_impairments imp
1632: where imp.book_type_code = p_book_type_code
1633: and imp.status = l_mode
1634: and imp.request_id = p_request_id
1635: and bk.book_type_code = p_book_type_code

Line 1661: from fa_books bk , fa_impairments imp

1657: --Bug# 7292608 When updating uploaded impairment,existing row needs to be deleted first
1658: delete from fa_itf_impairments itmp
1659: where exists
1660: (select 'Uploaded impairment'
1661: from fa_books bk , fa_impairments imp
1662: where imp.book_type_code = p_book_type_code
1663: and imp.status = l_mode
1664: and imp.request_id = p_request_id
1665: and bk.book_type_code = p_book_type_code

Line 1747: , fa_impairments imp

1743: , imp.SPLIT3_REASON
1744: , imp.SPLIT3_PERCENT
1745: , imp.SPLIT3_LOSS_ACCT -- End of Bug 6666666
1746: from fa_books bk
1747: , fa_impairments imp
1748: where imp.book_type_code = p_book_type_code
1749: and imp.status = l_mode
1750: and imp.request_id = p_request_id
1751: and bk.book_type_code = p_book_type_code

Line 1971: update fa_impairments

1967: raise rbi_err;
1968: end if;
1969: end if;
1970:
1971: update fa_impairments
1972: set status = l_new_status
1973: where status = l_status
1974: and request_id = p_request_id;
1975: