DBA Data[Home] [Help]

APPS.IGI_IAC_RECLASS_PKG dependencies on FA_DISTRIBUTION_HISTORY

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

444: +===============================================================================+
445: | Procedure to prorate the amounts based on the units assigned |
446: ================================================================================+
447: */
448: PROCEDURE Prorate_amount_for_dist(P_dist_id in FA_DISTRIBUTION_HISTORY.DISTRIBUTION_ID%type,
449: P_units_dist in number,
450: P_units_total in number,
451: P_reval_reserve in out NOCOPY number,
452: P_general_fund in out NOCOPY number,

Line 531: from fa_distribution_history

527: end if;
528:
529: select units_assigned
530: into l_units_assigned
531: from fa_distribution_history
532: where book_type_code = fp_det_balances.book_type_code
533: and asset_id = fp_det_balances.asset_id
534: and distribution_id = fp_det_balances.distribution_id
535: ;

Line 1329: FROM fa_distribution_history

1325: CURSOR c_all_dist IS
1326: SELECT distribution_id,
1327: transaction_header_id_in,
1328: units_assigned
1329: FROM fa_distribution_history
1330: WHERE asset_id=l_asset_hdr_rec.asset_id
1331: AND book_type_code=l_asset_hdr_rec.book_type_code
1332: AND transaction_header_id_out=l_trans_rec.transaction_header_id;
1333:

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

1332: AND transaction_header_id_out=l_trans_rec.transaction_header_id;
1333:
1334: /* Cursor to select the distribution(s) undergoing the reclasss */
1335:
1336: CURSOR c_old_dist(c_dist_id IN FA_DISTRIBUTION_HISTORY.distribution_id%TYPE) IS
1337: SELECT distribution_id
1338: FROM fa_distribution_history
1339: WHERE asset_id=l_asset_hdr_rec.asset_id
1340: AND book_type_code=l_asset_hdr_rec.book_type_code

Line 1338: FROM fa_distribution_history

1334: /* Cursor to select the distribution(s) undergoing the reclasss */
1335:
1336: CURSOR c_old_dist(c_dist_id IN FA_DISTRIBUTION_HISTORY.distribution_id%TYPE) IS
1337: SELECT distribution_id
1338: FROM fa_distribution_history
1339: WHERE asset_id=l_asset_hdr_rec.asset_id
1340: AND book_type_code=l_asset_hdr_rec.book_type_code
1341: AND transaction_header_id_out=l_trans_rec.transaction_header_id
1342: AND distribution_id=c_dist_id;

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

1342: AND distribution_id=c_dist_id;
1343:
1344: /* Cursor to select the new distribution(s) undergoing the reclasss */
1345:
1346: CURSOR c_new_dist(c_dist_id IN FA_DISTRIBUTION_HISTORY.distribution_id%TYPE) IS
1347: SELECT distribution_id
1348: FROM fa_distribution_history
1349: WHERE asset_id=l_asset_hdr_rec.asset_id
1350: AND book_type_code=l_asset_hdr_rec.book_type_code

Line 1348: FROM fa_distribution_history

1344: /* Cursor to select the new distribution(s) undergoing the reclasss */
1345:
1346: CURSOR c_new_dist(c_dist_id IN FA_DISTRIBUTION_HISTORY.distribution_id%TYPE) IS
1347: SELECT distribution_id
1348: FROM fa_distribution_history
1349: WHERE asset_id=l_asset_hdr_rec.asset_id
1350: AND book_type_code=l_asset_hdr_rec.book_type_code
1351: AND transaction_header_id_in=l_trans_rec.transaction_header_id
1352: AND distribution_id=c_dist_id;

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

1352: AND distribution_id=c_dist_id;
1353:
1354: /* Cursor to select the details of impacted distribution in this reclass*/
1355:
1356: CURSOR c_impacted_dist(c_imp_dist_id FA_DISTRIBUTION_HISTORY.distribution_id%TYPE) IS
1357: SELECT a.distribution_id,
1358: a.units_assigned
1359: FROM fa_distribution_history a, fa_distribution_history b
1360: WHERE a.asset_id=l_asset_hdr_rec.asset_id

Line 1359: FROM fa_distribution_history a, fa_distribution_history b

1355:
1356: CURSOR c_impacted_dist(c_imp_dist_id FA_DISTRIBUTION_HISTORY.distribution_id%TYPE) IS
1357: SELECT a.distribution_id,
1358: a.units_assigned
1359: FROM fa_distribution_history a, fa_distribution_history b
1360: WHERE a.asset_id=l_asset_hdr_rec.asset_id
1361: AND a.book_type_code=l_asset_hdr_rec.book_type_code
1362: AND a.asset_id = b.asset_id
1363: AND a.book_type_code = b.book_type_code

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

1366: AND nvl(a.location_id,-1) = nvl(b.location_id,-1)
1367: AND a.units_assigned = b.units_assigned
1368: AND b.distribution_id=c_imp_dist_id;
1369:
1370: CURSOR c_impacted_dist_new(c_imp_dist_id FA_DISTRIBUTION_HISTORY.distribution_id%TYPE ,
1371: c_imp_dist_id_new FA_DISTRIBUTION_HISTORY.distribution_id%TYPE) IS
1372: SELECT a.distribution_id,
1373: a.units_assigned
1374: FROM fa_distribution_history a, fa_distribution_history b

Line 1371: c_imp_dist_id_new FA_DISTRIBUTION_HISTORY.distribution_id%TYPE) IS

1367: AND a.units_assigned = b.units_assigned
1368: AND b.distribution_id=c_imp_dist_id;
1369:
1370: CURSOR c_impacted_dist_new(c_imp_dist_id FA_DISTRIBUTION_HISTORY.distribution_id%TYPE ,
1371: c_imp_dist_id_new FA_DISTRIBUTION_HISTORY.distribution_id%TYPE) IS
1372: SELECT a.distribution_id,
1373: a.units_assigned
1374: FROM fa_distribution_history a, fa_distribution_history b
1375: WHERE a.asset_id=l_asset_hdr_rec.asset_id

Line 1374: FROM fa_distribution_history a, fa_distribution_history b

1370: CURSOR c_impacted_dist_new(c_imp_dist_id FA_DISTRIBUTION_HISTORY.distribution_id%TYPE ,
1371: c_imp_dist_id_new FA_DISTRIBUTION_HISTORY.distribution_id%TYPE) IS
1372: SELECT a.distribution_id,
1373: a.units_assigned
1374: FROM fa_distribution_history a, fa_distribution_history b
1375: WHERE a.asset_id=l_asset_hdr_rec.asset_id
1376: AND a.book_type_code=l_asset_hdr_rec.book_type_code
1377: AND a.asset_id = b.asset_id
1378: AND a.book_type_code = b.book_type_code

Line 1412: FROM fa_distribution_history

1408: /* Cursor to find the total number of units for the asset itself ( active) */
1409:
1410: CURSOR c_units IS
1411: SELECT sum(units_assigned)
1412: FROM fa_distribution_history
1413: WHERE asset_id=l_asset_hdr_rec.asset_id
1414: AND book_type_code=l_asset_hdr_rec.book_type_code
1415: AND transaction_header_id_out IS NULL;
1416:

Line 1421: FROM fa_distribution_history

1417: /* Cursor to find the total no of units involved in the transfer of old dist to new */
1418:
1419: CURSOR c_dist_units IS
1420: SELECT sum(units_assigned)
1421: FROM fa_distribution_history
1422: WHERE asset_id=l_asset_hdr_rec.asset_id
1423: AND book_type_code=l_asset_hdr_rec.book_type_code
1424: AND transaction_header_id_in=l_trans_rec.transaction_header_id;
1425:

Line 1476: FROM igi_iac_det_balances iadb,fa_distribution_history fdh

1472: CURSOR c_backlog_data(c_current_period_Counter fa_deprn_periods.period_counter%TYPE) IS
1473: SELECT sum(nvl(iadb.reval_reserve_backlog,0)) reval_reserve_backlog,
1474: sum(nvl(iadb.operating_acct_backlog,0)) operating_acct_backlog,
1475: sum(nvl(iadb.general_fund_per,0)) general_fund_per
1476: FROM igi_iac_det_balances iadb,fa_distribution_history fdh
1477: WHERE iadb.book_type_code = l_asset_hdr_rec.book_type_code
1478: AND iadb.period_counter = c_current_period_counter
1479: AND iadb.asset_id=l_asset_hdr_rec.asset_id
1480: AND iadb.asset_id=fdh.asset_id

Line 1533: l_dist_units FA_DISTRIBUTION_HISTORY.units_assigned%TYPE;

1529: l_amounts c_amounts%ROWTYPE;
1530: l_backlog_data c_backlog_data%ROWTYPE;
1531: l_get_deprn_dist c_get_deprn_dist%ROWTYPE;
1532: l_old_dist c_old_dist%ROWTYPE;
1533: l_dist_units FA_DISTRIBUTION_HISTORY.units_assigned%TYPE;
1534: l_prd_rec IGI_IAC_TYPES.prd_rec;
1535: l_prd_rec_prior IGI_IAC_TYPES.prd_rec;
1536:
1537: l_prev_data c_prev_data%ROWTYPE;

Line 1543: l_units FA_DISTRIBUTION_HISTORY.units_assigned%TYPE;

1539: l_current_period_counter FA_DEPRN_PERIODS.period_counter%TYPE;
1540: l_start_period_counter FA_DEPRN_PERIODS.period_counter%TYPE;
1541:
1542: l_asset_num FA_ADDITIONS.asset_number%TYPE;
1543: l_units FA_DISTRIBUTION_HISTORY.units_assigned%TYPE;
1544: l_reval_reserve IGI_IAC_DET_BALANCES.reval_reserve_cost%TYPE;
1545: l_general_fund IGI_IAC_DET_BALANCES.general_fund_acc%TYPE;
1546: l_Backlog_deprn_reserve IGI_IAC_DET_BALANCES.deprn_reserve_backlog%TYPE;
1547: l_deprn_reserve IGI_IAC_DET_BALANCES.deprn_reserve%TYPE;

Line 1999: FROM fa_distribution_history

1995: CURSOR c_all_dist IS
1996: SELECT distribution_id,
1997: transaction_header_id_in,
1998: units_assigned
1999: FROM fa_distribution_history
2000: WHERE asset_id=l_asset_hdr_rec.asset_id
2001: AND book_type_code=l_asset_hdr_rec.book_type_code
2002: AND transaction_header_id_out=l_trans_rec.transaction_header_id;
2003:

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

2002: AND transaction_header_id_out=l_trans_rec.transaction_header_id;
2003:
2004: /* Cursor to select the distribution(s) undergoing the reclasss */
2005:
2006: CURSOR c_old_dist(c_dist_id in FA_DISTRIBUTION_HISTORY.distribution_id%type) IS
2007: SELECT distribution_id
2008: FROM fa_distribution_history
2009: WHERE asset_id=l_asset_hdr_rec.asset_id
2010: AND book_type_code=l_asset_hdr_rec.book_type_code

Line 2008: FROM fa_distribution_history

2004: /* Cursor to select the distribution(s) undergoing the reclasss */
2005:
2006: CURSOR c_old_dist(c_dist_id in FA_DISTRIBUTION_HISTORY.distribution_id%type) IS
2007: SELECT distribution_id
2008: FROM fa_distribution_history
2009: WHERE asset_id=l_asset_hdr_rec.asset_id
2010: AND book_type_code=l_asset_hdr_rec.book_type_code
2011: AND transaction_header_id_out=l_trans_rec.transaction_header_id
2012: AND distribution_id=c_dist_id;

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

2012: AND distribution_id=c_dist_id;
2013:
2014: /* Cursor to select the new distribution(s) undergoing the reclasss */
2015:
2016: CURSOR c_new_dist(c_dist_id in FA_DISTRIBUTION_HISTORY.distribution_id%type) IS
2017: SELECT distribution_id
2018: FROM fa_distribution_history
2019: WHERE asset_id=l_asset_hdr_rec.asset_id
2020: AND book_type_code=l_asset_hdr_rec.book_type_code

Line 2018: FROM fa_distribution_history

2014: /* Cursor to select the new distribution(s) undergoing the reclasss */
2015:
2016: CURSOR c_new_dist(c_dist_id in FA_DISTRIBUTION_HISTORY.distribution_id%type) IS
2017: SELECT distribution_id
2018: FROM fa_distribution_history
2019: WHERE asset_id=l_asset_hdr_rec.asset_id
2020: AND book_type_code=l_asset_hdr_rec.book_type_code
2021: AND transaction_header_id_in=l_trans_rec.transaction_header_id
2022: AND distribution_id=c_dist_id;

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

2022: AND distribution_id=c_dist_id;
2023:
2024: /* Cursor to select the details of impacted distribution in this reclass*/
2025:
2026: CURSOR c_impacted_dist(c_imp_dist_id FA_DISTRIBUTION_HISTORY.distribution_id%type) IS
2027: SELECT a.distribution_id,
2028: a.units_assigned
2029: FROM fa_distribution_history a, fa_distribution_history b
2030: WHERE a.asset_id=l_asset_hdr_rec.asset_id

Line 2029: FROM fa_distribution_history a, fa_distribution_history b

2025:
2026: CURSOR c_impacted_dist(c_imp_dist_id FA_DISTRIBUTION_HISTORY.distribution_id%type) IS
2027: SELECT a.distribution_id,
2028: a.units_assigned
2029: FROM fa_distribution_history a, fa_distribution_history b
2030: WHERE a.asset_id=l_asset_hdr_rec.asset_id
2031: AND a.book_type_code=l_asset_hdr_rec.book_type_code
2032: AND a.asset_id = b.asset_id
2033: AND a.book_type_code = b.book_type_code

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

2036: AND nvl(a.location_id,-1) = nvl(b.location_id,-1)
2037: AND a.units_assigned = b.units_assigned
2038: AND b.distribution_id=c_imp_dist_id;
2039:
2040: CURSOR c_impacted_dist_new(c_imp_dist_id FA_DISTRIBUTION_HISTORY.distribution_id%type ,
2041: c_imp_dist_id_new FA_DISTRIBUTION_HISTORY.distribution_id%type) IS
2042: SELECT a.distribution_id,
2043: a.units_assigned
2044: FROM fa_distribution_history a, fa_distribution_history b

Line 2041: c_imp_dist_id_new FA_DISTRIBUTION_HISTORY.distribution_id%type) IS

2037: AND a.units_assigned = b.units_assigned
2038: AND b.distribution_id=c_imp_dist_id;
2039:
2040: CURSOR c_impacted_dist_new(c_imp_dist_id FA_DISTRIBUTION_HISTORY.distribution_id%type ,
2041: c_imp_dist_id_new FA_DISTRIBUTION_HISTORY.distribution_id%type) IS
2042: SELECT a.distribution_id,
2043: a.units_assigned
2044: FROM fa_distribution_history a, fa_distribution_history b
2045: WHERE a.asset_id=l_asset_hdr_rec.asset_id

Line 2044: FROM fa_distribution_history a, fa_distribution_history b

2040: CURSOR c_impacted_dist_new(c_imp_dist_id FA_DISTRIBUTION_HISTORY.distribution_id%type ,
2041: c_imp_dist_id_new FA_DISTRIBUTION_HISTORY.distribution_id%type) IS
2042: SELECT a.distribution_id,
2043: a.units_assigned
2044: FROM fa_distribution_history a, fa_distribution_history b
2045: WHERE a.asset_id=l_asset_hdr_rec.asset_id
2046: AND a.book_type_code=l_asset_hdr_rec.book_type_code
2047: AND a.asset_id = b.asset_id
2048: AND a.book_type_code = b.book_type_code

Line 2092: FROM fa_distribution_history

2088: /* Cursor to find the total number of units for the asset itself ( active) */
2089:
2090: CURSOR c_units IS
2091: SELECT sum(units_assigned)
2092: FROM fa_distribution_history
2093: WHERE asset_id=l_asset_hdr_rec.asset_id
2094: AND book_type_code=l_asset_hdr_rec.book_type_code
2095: AND transaction_header_id_out is null;
2096:

Line 2101: FROM fa_distribution_history

2097: /* Cursor to find the total no of units involved in the transfer of old dist to new */
2098:
2099: CURSOR c_dist_units IS
2100: SELECT sum(units_assigned)
2101: FROM fa_distribution_history
2102: WHERE asset_id=l_asset_hdr_rec.asset_id
2103: AND book_type_code=l_asset_hdr_rec.book_type_code
2104: AND transaction_header_id_in=l_trans_rec.transaction_header_id;
2105:

Line 2155: FROM igi_iac_det_balances iadb,fa_distribution_history fdh

2151: CURSOR c_backlog_data(c_current_period_Counter fa_deprn_periods.period_counter%type) IS
2152: SELECT sum(nvl(iadb.reval_reserve_backlog,0)) reval_reserve_backlog,
2153: sum(nvl(iadb.operating_acct_backlog,0)) operating_acct_backlog,
2154: sum(nvl(iadb.general_fund_per,0)) general_fund_per
2155: FROM igi_iac_det_balances iadb,fa_distribution_history fdh
2156: WHERE iadb.book_type_code = l_asset_hdr_rec.book_type_code
2157: AND iadb.period_counter = c_current_period_counter
2158: AND iadb.asset_id=l_asset_hdr_rec.asset_id
2159: AND iadb.asset_id=fdh.asset_id

Line 2211: l_dist_units FA_DISTRIBUTION_HISTORY.units_assigned%type;

2207: l_amounts c_amounts%rowtype;
2208: l_backlog_data c_backlog_data%rowtype;
2209: l_get_deprn_dist c_get_deprn_dist%rowtype;
2210: l_old_dist c_old_dist%rowtype;
2211: l_dist_units FA_DISTRIBUTION_HISTORY.units_assigned%type;
2212: l_prd_rec IGI_IAC_TYPES.prd_rec;
2213: l_prd_rec_prior IGI_IAC_TYPES.prd_rec;
2214:
2215: l_prev_data c_prev_data%rowtype;

Line 2221: l_units FA_DISTRIBUTION_HISTORY.units_assigned%type;

2217: l_current_period_counter FA_DEPRN_PERIODS.period_counter%type;
2218: l_start_period_counter FA_DEPRN_PERIODS.period_counter%type;
2219:
2220: l_asset_num FA_ADDITIONS.asset_number%type;
2221: l_units FA_DISTRIBUTION_HISTORY.units_assigned%type;
2222: l_reval_reserve IGI_IAC_DET_BALANCES.reval_reserve_cost%type;
2223: l_general_fund IGI_IAC_DET_BALANCES.general_fund_acc%type;
2224: l_Backlog_deprn_reserve IGI_IAC_DET_BALANCES.deprn_reserve_backlog%type;
2225: l_deprn_reserve IGI_IAC_DET_BALANCES.deprn_reserve%type;