DBA Data[Home] [Help]

APPS.IGI_IAC_RECLASS_PKG dependencies on FA_DISTRIBUTION_HISTORY

Line 471: PROCEDURE Prorate_amount_for_dist(P_dist_id in FA_DISTRIBUTION_HISTORY.DISTRIBUTION_ID%type,

467: +===============================================================================+
468: | Procedure to prorate the amounts based on the units assigned |
469: ================================================================================+
470: */
471: PROCEDURE Prorate_amount_for_dist(P_dist_id in FA_DISTRIBUTION_HISTORY.DISTRIBUTION_ID%type,
472: P_units_dist in number,
473: P_units_total in number,
474: P_reval_reserve in out NOCOPY number,
475: P_general_fund in out NOCOPY number,

Line 564: from fa_distribution_history

560: end if;
561:
562: select units_assigned
563: into l_units_assigned
564: from fa_distribution_history
565: where book_type_code = fp_det_balances.book_type_code
566: and asset_id = fp_det_balances.asset_id
567: and distribution_id = fp_det_balances.distribution_id
568: ;

Line 1362: FROM fa_distribution_history

1358: CURSOR c_all_dist IS
1359: SELECT distribution_id,
1360: transaction_header_id_in,
1361: units_assigned
1362: FROM fa_distribution_history
1363: WHERE asset_id=l_asset_hdr_rec.asset_id
1364: AND book_type_code=l_asset_hdr_rec.book_type_code
1365: AND transaction_header_id_out=l_trans_rec.transaction_header_id;
1366:

Line 1369: CURSOR c_old_dist(c_dist_id IN FA_DISTRIBUTION_HISTORY.distribution_id%TYPE) IS

1365: AND transaction_header_id_out=l_trans_rec.transaction_header_id;
1366:
1367: /* Cursor to select the distribution(s) undergoing the reclasss */
1368:
1369: CURSOR c_old_dist(c_dist_id IN FA_DISTRIBUTION_HISTORY.distribution_id%TYPE) IS
1370: SELECT distribution_id
1371: FROM fa_distribution_history
1372: WHERE asset_id=l_asset_hdr_rec.asset_id
1373: AND book_type_code=l_asset_hdr_rec.book_type_code

Line 1371: FROM fa_distribution_history

1367: /* Cursor to select the distribution(s) undergoing the reclasss */
1368:
1369: CURSOR c_old_dist(c_dist_id IN FA_DISTRIBUTION_HISTORY.distribution_id%TYPE) IS
1370: SELECT distribution_id
1371: FROM fa_distribution_history
1372: WHERE asset_id=l_asset_hdr_rec.asset_id
1373: AND book_type_code=l_asset_hdr_rec.book_type_code
1374: AND transaction_header_id_out=l_trans_rec.transaction_header_id
1375: AND distribution_id=c_dist_id;

Line 1379: CURSOR c_new_dist(c_dist_id IN FA_DISTRIBUTION_HISTORY.distribution_id%TYPE) IS

1375: AND distribution_id=c_dist_id;
1376:
1377: /* Cursor to select the new distribution(s) undergoing the reclasss */
1378:
1379: CURSOR c_new_dist(c_dist_id IN FA_DISTRIBUTION_HISTORY.distribution_id%TYPE) IS
1380: SELECT distribution_id
1381: FROM fa_distribution_history
1382: WHERE asset_id=l_asset_hdr_rec.asset_id
1383: AND book_type_code=l_asset_hdr_rec.book_type_code

Line 1381: FROM fa_distribution_history

1377: /* Cursor to select the new distribution(s) undergoing the reclasss */
1378:
1379: CURSOR c_new_dist(c_dist_id IN FA_DISTRIBUTION_HISTORY.distribution_id%TYPE) IS
1380: SELECT distribution_id
1381: FROM fa_distribution_history
1382: WHERE asset_id=l_asset_hdr_rec.asset_id
1383: AND book_type_code=l_asset_hdr_rec.book_type_code
1384: AND transaction_header_id_in=l_trans_rec.transaction_header_id
1385: AND distribution_id=c_dist_id;

Line 1389: CURSOR c_impacted_dist(c_imp_dist_id FA_DISTRIBUTION_HISTORY.distribution_id%TYPE) IS

1385: AND distribution_id=c_dist_id;
1386:
1387: /* Cursor to select the details of impacted distribution in this reclass*/
1388:
1389: CURSOR c_impacted_dist(c_imp_dist_id FA_DISTRIBUTION_HISTORY.distribution_id%TYPE) IS
1390: SELECT a.distribution_id,
1391: a.units_assigned
1392: FROM fa_distribution_history a, fa_distribution_history b
1393: WHERE a.asset_id=l_asset_hdr_rec.asset_id

Line 1392: FROM fa_distribution_history a, fa_distribution_history b

1388:
1389: CURSOR c_impacted_dist(c_imp_dist_id FA_DISTRIBUTION_HISTORY.distribution_id%TYPE) IS
1390: SELECT a.distribution_id,
1391: a.units_assigned
1392: FROM fa_distribution_history a, fa_distribution_history b
1393: WHERE a.asset_id=l_asset_hdr_rec.asset_id
1394: AND a.book_type_code=l_asset_hdr_rec.book_type_code
1395: AND a.asset_id = b.asset_id
1396: AND a.book_type_code = b.book_type_code

Line 1403: CURSOR c_impacted_dist_new(c_imp_dist_id FA_DISTRIBUTION_HISTORY.distribution_id%TYPE ,

1399: AND nvl(a.location_id,-1) = nvl(b.location_id,-1)
1400: AND a.units_assigned = b.units_assigned
1401: AND b.distribution_id=c_imp_dist_id;
1402:
1403: CURSOR c_impacted_dist_new(c_imp_dist_id FA_DISTRIBUTION_HISTORY.distribution_id%TYPE ,
1404: c_imp_dist_id_new FA_DISTRIBUTION_HISTORY.distribution_id%TYPE) IS
1405: SELECT a.distribution_id,
1406: a.units_assigned
1407: FROM fa_distribution_history a, fa_distribution_history b

Line 1404: c_imp_dist_id_new FA_DISTRIBUTION_HISTORY.distribution_id%TYPE) IS

1400: AND a.units_assigned = b.units_assigned
1401: AND b.distribution_id=c_imp_dist_id;
1402:
1403: CURSOR c_impacted_dist_new(c_imp_dist_id FA_DISTRIBUTION_HISTORY.distribution_id%TYPE ,
1404: c_imp_dist_id_new FA_DISTRIBUTION_HISTORY.distribution_id%TYPE) IS
1405: SELECT a.distribution_id,
1406: a.units_assigned
1407: FROM fa_distribution_history a, fa_distribution_history b
1408: WHERE a.asset_id=l_asset_hdr_rec.asset_id

Line 1407: FROM fa_distribution_history a, fa_distribution_history b

1403: CURSOR c_impacted_dist_new(c_imp_dist_id FA_DISTRIBUTION_HISTORY.distribution_id%TYPE ,
1404: c_imp_dist_id_new FA_DISTRIBUTION_HISTORY.distribution_id%TYPE) IS
1405: SELECT a.distribution_id,
1406: a.units_assigned
1407: FROM fa_distribution_history a, fa_distribution_history b
1408: WHERE a.asset_id=l_asset_hdr_rec.asset_id
1409: AND a.book_type_code=l_asset_hdr_rec.book_type_code
1410: AND a.asset_id = b.asset_id
1411: AND a.book_type_code = b.book_type_code

Line 1445: FROM fa_distribution_history

1441: /* Cursor to find the total number of units for the asset itself ( active) */
1442:
1443: CURSOR c_units IS
1444: SELECT sum(units_assigned)
1445: FROM fa_distribution_history
1446: WHERE asset_id=l_asset_hdr_rec.asset_id
1447: AND book_type_code=l_asset_hdr_rec.book_type_code
1448: AND transaction_header_id_out IS NULL;
1449:

Line 1454: FROM fa_distribution_history

1450: /* Cursor to find the total no of units involved in the transfer of old dist to new */
1451:
1452: CURSOR c_dist_units IS
1453: SELECT sum(units_assigned)
1454: FROM fa_distribution_history
1455: WHERE asset_id=l_asset_hdr_rec.asset_id
1456: AND book_type_code=l_asset_hdr_rec.book_type_code
1457: AND transaction_header_id_in=l_trans_rec.transaction_header_id;
1458:

Line 1509: FROM igi_iac_det_balances iadb,fa_distribution_history fdh

1505: CURSOR c_backlog_data(c_current_period_Counter fa_deprn_periods.period_counter%TYPE) IS
1506: SELECT sum(nvl(iadb.reval_reserve_backlog,0)) reval_reserve_backlog,
1507: sum(nvl(iadb.operating_acct_backlog,0)) operating_acct_backlog,
1508: sum(nvl(iadb.general_fund_per,0)) general_fund_per
1509: FROM igi_iac_det_balances iadb,fa_distribution_history fdh
1510: WHERE iadb.book_type_code = l_asset_hdr_rec.book_type_code
1511: AND iadb.period_counter = c_current_period_counter
1512: AND iadb.asset_id=l_asset_hdr_rec.asset_id
1513: AND iadb.asset_id=fdh.asset_id

Line 1566: l_dist_units FA_DISTRIBUTION_HISTORY.units_assigned%TYPE;

1562: l_amounts c_amounts%ROWTYPE;
1563: l_backlog_data c_backlog_data%ROWTYPE;
1564: l_get_deprn_dist c_get_deprn_dist%ROWTYPE;
1565: l_old_dist c_old_dist%ROWTYPE;
1566: l_dist_units FA_DISTRIBUTION_HISTORY.units_assigned%TYPE;
1567: l_prd_rec IGI_IAC_TYPES.prd_rec;
1568: l_prd_rec_prior IGI_IAC_TYPES.prd_rec;
1569:
1570: l_prev_data c_prev_data%ROWTYPE;

Line 1576: l_units FA_DISTRIBUTION_HISTORY.units_assigned%TYPE;

1572: l_current_period_counter FA_DEPRN_PERIODS.period_counter%TYPE;
1573: l_start_period_counter FA_DEPRN_PERIODS.period_counter%TYPE;
1574:
1575: l_asset_num FA_ADDITIONS.asset_number%TYPE;
1576: l_units FA_DISTRIBUTION_HISTORY.units_assigned%TYPE;
1577: l_reval_reserve IGI_IAC_DET_BALANCES.reval_reserve_cost%TYPE;
1578: l_general_fund IGI_IAC_DET_BALANCES.general_fund_acc%TYPE;
1579: l_Backlog_deprn_reserve IGI_IAC_DET_BALANCES.deprn_reserve_backlog%TYPE;
1580: l_deprn_reserve IGI_IAC_DET_BALANCES.deprn_reserve%TYPE;

Line 2032: FROM fa_distribution_history

2028: CURSOR c_all_dist IS
2029: SELECT distribution_id,
2030: transaction_header_id_in,
2031: units_assigned
2032: FROM fa_distribution_history
2033: WHERE asset_id=l_asset_hdr_rec.asset_id
2034: AND book_type_code=l_asset_hdr_rec.book_type_code
2035: AND transaction_header_id_out=l_trans_rec.transaction_header_id;
2036:

Line 2039: CURSOR c_old_dist(c_dist_id in FA_DISTRIBUTION_HISTORY.distribution_id%type) IS

2035: AND transaction_header_id_out=l_trans_rec.transaction_header_id;
2036:
2037: /* Cursor to select the distribution(s) undergoing the reclasss */
2038:
2039: CURSOR c_old_dist(c_dist_id in FA_DISTRIBUTION_HISTORY.distribution_id%type) IS
2040: SELECT distribution_id
2041: FROM fa_distribution_history
2042: WHERE asset_id=l_asset_hdr_rec.asset_id
2043: AND book_type_code=l_asset_hdr_rec.book_type_code

Line 2041: FROM fa_distribution_history

2037: /* Cursor to select the distribution(s) undergoing the reclasss */
2038:
2039: CURSOR c_old_dist(c_dist_id in FA_DISTRIBUTION_HISTORY.distribution_id%type) IS
2040: SELECT distribution_id
2041: FROM fa_distribution_history
2042: WHERE asset_id=l_asset_hdr_rec.asset_id
2043: AND book_type_code=l_asset_hdr_rec.book_type_code
2044: AND transaction_header_id_out=l_trans_rec.transaction_header_id
2045: AND distribution_id=c_dist_id;

Line 2049: CURSOR c_new_dist(c_dist_id in FA_DISTRIBUTION_HISTORY.distribution_id%type) IS

2045: AND distribution_id=c_dist_id;
2046:
2047: /* Cursor to select the new distribution(s) undergoing the reclasss */
2048:
2049: CURSOR c_new_dist(c_dist_id in FA_DISTRIBUTION_HISTORY.distribution_id%type) IS
2050: SELECT distribution_id
2051: FROM fa_distribution_history
2052: WHERE asset_id=l_asset_hdr_rec.asset_id
2053: AND book_type_code=l_asset_hdr_rec.book_type_code

Line 2051: FROM fa_distribution_history

2047: /* Cursor to select the new distribution(s) undergoing the reclasss */
2048:
2049: CURSOR c_new_dist(c_dist_id in FA_DISTRIBUTION_HISTORY.distribution_id%type) IS
2050: SELECT distribution_id
2051: FROM fa_distribution_history
2052: WHERE asset_id=l_asset_hdr_rec.asset_id
2053: AND book_type_code=l_asset_hdr_rec.book_type_code
2054: AND transaction_header_id_in=l_trans_rec.transaction_header_id
2055: AND distribution_id=c_dist_id;

Line 2059: CURSOR c_impacted_dist(c_imp_dist_id FA_DISTRIBUTION_HISTORY.distribution_id%type) IS

2055: AND distribution_id=c_dist_id;
2056:
2057: /* Cursor to select the details of impacted distribution in this reclass*/
2058:
2059: CURSOR c_impacted_dist(c_imp_dist_id FA_DISTRIBUTION_HISTORY.distribution_id%type) IS
2060: SELECT a.distribution_id,
2061: a.units_assigned
2062: FROM fa_distribution_history a, fa_distribution_history b
2063: WHERE a.asset_id=l_asset_hdr_rec.asset_id

Line 2062: FROM fa_distribution_history a, fa_distribution_history b

2058:
2059: CURSOR c_impacted_dist(c_imp_dist_id FA_DISTRIBUTION_HISTORY.distribution_id%type) IS
2060: SELECT a.distribution_id,
2061: a.units_assigned
2062: FROM fa_distribution_history a, fa_distribution_history b
2063: WHERE a.asset_id=l_asset_hdr_rec.asset_id
2064: AND a.book_type_code=l_asset_hdr_rec.book_type_code
2065: AND a.asset_id = b.asset_id
2066: AND a.book_type_code = b.book_type_code

Line 2073: CURSOR c_impacted_dist_new(c_imp_dist_id FA_DISTRIBUTION_HISTORY.distribution_id%type ,

2069: AND nvl(a.location_id,-1) = nvl(b.location_id,-1)
2070: AND a.units_assigned = b.units_assigned
2071: AND b.distribution_id=c_imp_dist_id;
2072:
2073: CURSOR c_impacted_dist_new(c_imp_dist_id FA_DISTRIBUTION_HISTORY.distribution_id%type ,
2074: c_imp_dist_id_new FA_DISTRIBUTION_HISTORY.distribution_id%type) IS
2075: SELECT a.distribution_id,
2076: a.units_assigned
2077: FROM fa_distribution_history a, fa_distribution_history b

Line 2074: c_imp_dist_id_new FA_DISTRIBUTION_HISTORY.distribution_id%type) IS

2070: AND a.units_assigned = b.units_assigned
2071: AND b.distribution_id=c_imp_dist_id;
2072:
2073: CURSOR c_impacted_dist_new(c_imp_dist_id FA_DISTRIBUTION_HISTORY.distribution_id%type ,
2074: c_imp_dist_id_new FA_DISTRIBUTION_HISTORY.distribution_id%type) IS
2075: SELECT a.distribution_id,
2076: a.units_assigned
2077: FROM fa_distribution_history a, fa_distribution_history b
2078: WHERE a.asset_id=l_asset_hdr_rec.asset_id

Line 2077: FROM fa_distribution_history a, fa_distribution_history b

2073: CURSOR c_impacted_dist_new(c_imp_dist_id FA_DISTRIBUTION_HISTORY.distribution_id%type ,
2074: c_imp_dist_id_new FA_DISTRIBUTION_HISTORY.distribution_id%type) IS
2075: SELECT a.distribution_id,
2076: a.units_assigned
2077: FROM fa_distribution_history a, fa_distribution_history b
2078: WHERE a.asset_id=l_asset_hdr_rec.asset_id
2079: AND a.book_type_code=l_asset_hdr_rec.book_type_code
2080: AND a.asset_id = b.asset_id
2081: AND a.book_type_code = b.book_type_code

Line 2125: FROM fa_distribution_history

2121: /* Cursor to find the total number of units for the asset itself ( active) */
2122:
2123: CURSOR c_units IS
2124: SELECT sum(units_assigned)
2125: FROM fa_distribution_history
2126: WHERE asset_id=l_asset_hdr_rec.asset_id
2127: AND book_type_code=l_asset_hdr_rec.book_type_code
2128: AND transaction_header_id_out is null;
2129:

Line 2134: FROM fa_distribution_history

2130: /* Cursor to find the total no of units involved in the transfer of old dist to new */
2131:
2132: CURSOR c_dist_units IS
2133: SELECT sum(units_assigned)
2134: FROM fa_distribution_history
2135: WHERE asset_id=l_asset_hdr_rec.asset_id
2136: AND book_type_code=l_asset_hdr_rec.book_type_code
2137: AND transaction_header_id_in=l_trans_rec.transaction_header_id;
2138:

Line 2188: FROM igi_iac_det_balances iadb,fa_distribution_history fdh

2184: CURSOR c_backlog_data(c_current_period_Counter fa_deprn_periods.period_counter%type) IS
2185: SELECT sum(nvl(iadb.reval_reserve_backlog,0)) reval_reserve_backlog,
2186: sum(nvl(iadb.operating_acct_backlog,0)) operating_acct_backlog,
2187: sum(nvl(iadb.general_fund_per,0)) general_fund_per
2188: FROM igi_iac_det_balances iadb,fa_distribution_history fdh
2189: WHERE iadb.book_type_code = l_asset_hdr_rec.book_type_code
2190: AND iadb.period_counter = c_current_period_counter
2191: AND iadb.asset_id=l_asset_hdr_rec.asset_id
2192: AND iadb.asset_id=fdh.asset_id

Line 2244: l_dist_units FA_DISTRIBUTION_HISTORY.units_assigned%type;

2240: l_amounts c_amounts%rowtype;
2241: l_backlog_data c_backlog_data%rowtype;
2242: l_get_deprn_dist c_get_deprn_dist%rowtype;
2243: l_old_dist c_old_dist%rowtype;
2244: l_dist_units FA_DISTRIBUTION_HISTORY.units_assigned%type;
2245: l_prd_rec IGI_IAC_TYPES.prd_rec;
2246: l_prd_rec_prior IGI_IAC_TYPES.prd_rec;
2247:
2248: l_prev_data c_prev_data%rowtype;

Line 2254: l_units FA_DISTRIBUTION_HISTORY.units_assigned%type;

2250: l_current_period_counter FA_DEPRN_PERIODS.period_counter%type;
2251: l_start_period_counter FA_DEPRN_PERIODS.period_counter%type;
2252:
2253: l_asset_num FA_ADDITIONS.asset_number%type;
2254: l_units FA_DISTRIBUTION_HISTORY.units_assigned%type;
2255: l_reval_reserve IGI_IAC_DET_BALANCES.reval_reserve_cost%type;
2256: l_general_fund IGI_IAC_DET_BALANCES.general_fund_acc%type;
2257: l_Backlog_deprn_reserve IGI_IAC_DET_BALANCES.deprn_reserve_backlog%type;
2258: l_deprn_reserve IGI_IAC_DET_BALANCES.deprn_reserve%type;