DBA Data[Home] [Help]

APPS.FA_MASSADD_CREATE_PKG dependencies on FA_MASS_ADDITIONS_GT

Line 301: update /*+ index(FA_MASS_ADDITIONS_GT FA_MASS_ADDITIONS_GT_N4) */fa_mass_additions_gt

297:
298: G_child_iteration_count := G_child_iteration_count + 1;
299:
300: forall i in 1..p_invoice_dist_id_tbl.count
301: update /*+ index(FA_MASS_ADDITIONS_GT FA_MASS_ADDITIONS_GT_N4) */fa_mass_additions_gt
302: set mass_addition_id = fa_mass_additions_s.nextval
303: ,book_type_code = p_book_type_code
304: ,line_status = p_line_status_tbl(i)
305: ,posting_status = decode (nvl(fa_cache_pkg.fazcbc_record.IMPORT_ALLOC_INV_LINES_AS_NEW,'N'), 'N', p_posting_status_tbl(i), 'NEW') /* ER 14739752 */

Line 407: update /*+ index(FA_MASS_ADDITIONS_GT FA_MASS_ADDITIONS_GT_N4) */ fa_mass_additions_gt

403:
404: begin
405:
406: forall i in 1..p_invoice_dist_id_tbl.count
407: update /*+ index(FA_MASS_ADDITIONS_GT FA_MASS_ADDITIONS_GT_N4) */ fa_mass_additions_gt
408: set mass_addition_id = fa_mass_additions_s.nextval
409: ,book_type_code = p_book_type_code
410: ,line_status = 'VALID'
411: ,posting_status = 'NEW'

Line 451: update /*+ index(gt FA_MASS_ADDITIONS_GT_N3) */ fa_mass_additions_gt gt

447: end loop;
448:
449: -- flag these updated lines as parent MP where applicable
450: forall i in 1..l_mass_add_id_tbl.count
451: update /*+ index(gt FA_MASS_ADDITIONS_GT_N3) */ fa_mass_additions_gt gt
452: set split_merged_code = decode (nvl(fa_cache_pkg.fazcbc_record.IMPORT_ALLOC_INV_LINES_AS_NEW,'N'), 'N', 'MP',NULL), /* ER 14739752 */
453: merged_code = decode (nvl(fa_cache_pkg.fazcbc_record.IMPORT_ALLOC_INV_LINES_AS_NEW,'N'), 'N', 'MP',NULL)
454: where mass_addition_id = l_mass_add_id_tbl(i)
455: and book_type_code = p_book_type_code

Line 460: from fa_mass_additions_gt gt2

456: and invoice_payment_id is null -- exclude discounts
457: and ledger_category_code = 'P'
458: and exists
459: (select 1
460: from fa_mass_additions_gt gt2
461: where gt2.parent_invoice_dist_id = gt.invoice_distribution_id
462: and gt2.ledger_category_code = 'P' --Bug#10263900
463: and gt2.rowid <> gt.rowid);
464:

Line 607: select /*+ index(gt FA_MASS_ADDITIONS_GT_N2) */ rowid,

603: and mad2.posting_status not in ('DELETE', 'SPLIT')) ;
604:
605: -- Bug 13809266 : Allow unallocated lines from AP
606: cursor c_item_accrual is
607: select /*+ index(gt FA_MASS_ADDITIONS_GT_N2) */ rowid,
608: fa_mass_additions_s.nextval
609: from fa_mass_additions_gt gt
610: where (gt.line_type_lookup_code in ('ITEM', 'ACCRUAL') OR
611: (gt.line_type_lookup_code in ('NONREC_TAX','FREIGHT','MISCELLANEOUS') and

Line 609: from fa_mass_additions_gt gt

605: -- Bug 13809266 : Allow unallocated lines from AP
606: cursor c_item_accrual is
607: select /*+ index(gt FA_MASS_ADDITIONS_GT_N2) */ rowid,
608: fa_mass_additions_s.nextval
609: from fa_mass_additions_gt gt
610: where (gt.line_type_lookup_code in ('ITEM', 'ACCRUAL') OR
611: (gt.line_type_lookup_code in ('NONREC_TAX','FREIGHT','MISCELLANEOUS') and
612: gt.parent_invoice_dist_id is null and
613: nvl(fa_cache_pkg.fazcbc_record.allow_unallocated_lines_flag,'N') = 'Y')

Line 628: from fa_mass_additions_gt gt,

624: min(ad.asset_id),
625: min(mad.posting_status),
626: max(mad.asset_type),
627: count(distinct mad.rowid)
628: from fa_mass_additions_gt gt,
629: fa_mass_additions mad,
630: fa_additions_b ad
631: where ad.asset_number(+) = mad.asset_number
632: and mad.book_type_code = p_book_type_code

Line 651: fa_mass_additions_gt gt

647: count(distinct ai.rowid),
648: count(distinct ai.asset_id)
649: from fa_asset_invoices ai,
650: fa_additions_b ad,
651: fa_mass_additions_gt gt
652: where ai.invoice_distribution_id = gt.parent_invoice_dist_id
653: and ad.asset_id = ai.asset_id
654: and gt.ledger_category_code = 'P'
655: and gt.line_status = 'NEW'

Line 797: update fa_mass_additions_gt gt

793:
794:
795: /*code for second decode changed for Bug:10028857*/
796: l_sql := '
797: update fa_mass_additions_gt gt
798: set (asset_type, line_status, book_type_code, mass_addition_id) =
799: (select /*+ index(fca FA_CATEGORY_ACCOUNTS_GT_N2 */
800: decode(gt.asset_type,
801: null, decode(glcc.account_type,

Line 899: update fa_mass_additions_gt gt

895: end if;
896: /*10209969 - Need to update inside loop as l_mass_add_id_tbl is fetched in each iteration */
897: -- flag the parent as MP
898: forall i in 1..l_mass_add_id_tbl.count
899: update fa_mass_additions_gt gt
900: set split_merged_code = decode (nvl(fa_cache_pkg.fazcbc_record.IMPORT_ALLOC_INV_LINES_AS_NEW,'N'), 'N', 'MP',NULL), /* ER 14739752 */
901: merged_code = decode (nvl(fa_cache_pkg.fazcbc_record.IMPORT_ALLOC_INV_LINES_AS_NEW,'N'), 'N', 'MP',NULL)
902: where mass_addition_id = l_mass_add_id_tbl(i)
903: and book_type_code = p_book_type_code

Line 908: from fa_mass_additions_gt gt2

904: and invoice_payment_id is null
905: and ledger_category_code = 'P'
906: and exists
907: (select 1
908: from fa_mass_additions_gt gt2
909: where gt2.parent_invoice_dist_id = gt.invoice_distribution_id
910: and gt2.ledger_category_code = 'P' --Bug#10263900
911: and gt2.rowid <> gt.rowid);
912: end loop; -- bulk

Line 1152: update /*+ index(FA_MASS_ADDITIONS_GT FA_MASS_ADDITIONS_GT_N4) */ fa_mass_additions_gt

1148: -- will not be a MC line (unlike MAD case) and thus
1149: -- we need to do one update outside the recursive routine here
1150:
1151: forall i in 1..l_child_inv_dist_id1_tbl.count
1152: update /*+ index(FA_MASS_ADDITIONS_GT FA_MASS_ADDITIONS_GT_N4) */ fa_mass_additions_gt
1153: set mass_addition_id = fa_mass_additions_s.nextval,
1154: --book_type_code = p_book_type_code,
1155: line_status = 'VALID',
1156: posting_status = decode (nvl(fa_cache_pkg.fazcbc_record.IMPORT_ALLOC_INV_LINES_AS_NEW,'N'), 'N', 'ON HOLD','NEW'), /* ER 14739752 */

Line 1228: update /*+ index(gt FA_MASS_ADDITIONS_GT_N3) */ fa_mass_additions_gt gt

1224: end if;
1225:
1226: -- flag these updated lines as parent MP where applicable
1227: forall i in 1..l_child_mass_add_id1_tbl.count
1228: update /*+ index(gt FA_MASS_ADDITIONS_GT_N3) */ fa_mass_additions_gt gt
1229: set split_merged_code = decode (nvl(fa_cache_pkg.fazcbc_record.IMPORT_ALLOC_INV_LINES_AS_NEW,'N'), 'N', 'MP',NULL), /* ER 14739752 */
1230: merged_code = decode (nvl(fa_cache_pkg.fazcbc_record.IMPORT_ALLOC_INV_LINES_AS_NEW,'N'), 'N', 'MP',NULL)
1231: where invoice_distribution_id = l_child_inv_dist_id1A_tbl(i)
1232: and invoice_payment_id is null -- exclude discounts

Line 1237: from fa_mass_additions_gt gt2

1233: and book_type_code = p_book_type_code
1234: and ledger_category_code = 'P'
1235: and exists
1236: (select 1
1237: from fa_mass_additions_gt gt2
1238: where gt2.parent_invoice_dist_id = gt.invoice_distribution_id
1239: and gt2.rowid <> gt.rowid);
1240:
1241: -- process singles

Line 1277: ,'fa_mass_additions_gt'

1273:
1274: if (g_log_level_rec.statement_level) then
1275: fa_debug_pkg.add(l_calling_fn
1276: ,'Updating depreciate_flag in'
1277: ,'fa_mass_additions_gt'
1278: ,p_log_level_rec => g_log_level_rec);
1279: end if;
1280:
1281: -- update the depreciate_flag and inventorial on valid lines

Line 1282: update /*+ index(gt FA_MASS_ADDITIONS_GT_N1) */ fa_mass_additions_gt gt

1278: ,p_log_level_rec => g_log_level_rec);
1279: end if;
1280:
1281: -- update the depreciate_flag and inventorial on valid lines
1282: update /*+ index(gt FA_MASS_ADDITIONS_GT_N1) */ fa_mass_additions_gt gt
1283: set depreciate_flag =
1284: (select decode(gt.asset_type
1285: ,'EXPENSED','NO'
1286: ,nvl(CBD.depreciate_flag, 'YES'))

Line 1639: select /*+ index(gt FA_MASS_ADDITIONS_GT_N1) */

1635: invoice_distribution_id ,
1636: invoice_line_number ,
1637: invoice_payment_id ,
1638: warranty_number)
1639: select /*+ index(gt FA_MASS_ADDITIONS_GT_N1) */
1640: gt.mass_addition_id , --fa_mass_additions_s.nextval,
1641: gt.asset_number ,
1642: gt.tag_number ,
1643: gt.description ,

Line 1747: from fa_mass_additions_gt gt

1743: gt.invoice_distribution_id ,
1744: gt.invoice_line_number ,
1745: gt.invoice_payment_id ,
1746: gt.warranty_number
1747: from fa_mass_additions_gt gt
1748: where gt.book_type_code = p_book_type_code
1749: and gt.ledger_category_code = 'P'
1750: and gt.line_status = 'VALID';
1751:

Line 1779: fa_mass_additions_gt gt,

1775: mad.mass_addition_id,
1776: gt.fixed_assets_cost,
1777: 0
1778: from fa_mass_additions mad,
1779: fa_mass_additions_gt gt,
1780: fa_mc_book_controls mcbc
1781: where mad.book_type_code = p_book_type_code
1782: and mad.invoice_distribution_id = gt.invoice_distribution_id
1783: and nvl(mad.invoice_payment_id, -99) = nvl(gt.invoice_payment_id, -99)

Line 1803: ,'fa_mass_additions_gt'

1799:
1800: if (g_log_level_rec.statement_level) then
1801: fa_debug_pkg.add(l_calling_fn
1802: ,'Updating successful/processed rows in '
1803: ,'fa_mass_additions_gt'
1804: ,p_log_level_rec => g_log_level_rec);
1805: end if;
1806:
1807: savepoint FAMADC_create7;

Line 1809: update /*+ index(gt FA_MASS_ADDITIONS_GT_N1) */ fa_mass_additions_gt gt

1805: end if;
1806:
1807: savepoint FAMADC_create7;
1808:
1809: update /*+ index(gt FA_MASS_ADDITIONS_GT_N1) */ fa_mass_additions_gt gt
1810: set gt.line_status = 'PROCESSED'
1811: where book_type_code = p_book_type_code
1812: and line_status = 'VALID'
1813: and ledger_category_code = 'P'