DBA Data[Home] [Help]

APPS.PA_PURGE_COSTING dependencies on PA_EXPENDITURE_ITEMS_ALL

Line 238: pa_expenditure_items_all ei

234: l_fetch_complete BOOLEAN := FALSE;
235: cursor cdl_open_projects is
236: select cdl.rowid
237: from pa_cost_distribution_lines_all cdl,
238: pa_expenditure_items_all ei
239: where cdl.expenditure_item_id = ei.expenditure_item_id
240: and ei.expenditure_item_date <= p_txn_to_date
241: and ei.project_id = p_project_id;
242:

Line 596: from pa_expenditure_items_all ei,

592: l_fetch_complete BOOLEAN := FALSE;
593:
594: cursor c_open_cc_lines is
595: select cdl1.rowid
596: from pa_expenditure_items_all ei,
597: pa_cc_dist_lines_all cdl1
598: where cdl1.expenditure_item_id = ei.expenditure_item_id
599: and ei.expenditure_item_date <= p_txn_to_date
600: and ei.project_id = p_project_id;

Line 830: from pa_expenditure_items_all ei,

826: If ( l_mrc_flag = 'Y' and p_archive_flag <> 'Y' )Then
827: delete from pa_mc_cc_dist_lines_all cdl
828: where cdl.rowid in
829: ( select cdl1.rowid
830: from pa_expenditure_items_all ei,
831: pa_mc_cc_dist_lines_all cdl1
832: where cdl1.expenditure_item_id = ei.expenditure_item_id
833: and ei.project_id = p_project_id
834: and rownum < l_commit_size

Line 939: From pa_expenditure_items_all ei,

935: l_fetch_complete BOOLEAN := FALSE;
936:
937: Cursor c_open_exp_comm is
938: Select ec1.rowid
939: From pa_expenditure_items_all ei,
940: pa_expenditure_comments ec1
941: Where ei.expenditure_item_id = ec1.expenditure_item_id
942: And ei.expenditure_item_date <= p_txn_to_date
943: And ei.project_id = p_project_id;

Line 947: From pa_expenditure_items_all ei,

943: And ei.project_id = p_project_id;
944:
945: Cursor c_close_exp_comm is
946: Select ec1.rowid
947: From pa_expenditure_items_all ei,
948: pa_expenditure_comments ec1
949: Where ei.expenditure_item_id = ec1.expenditure_item_id
950: And ei.project_id = p_project_id;
951:

Line 1072: from pa_expenditure_items_all ei,

1068: if p_txn_to_date is NOT NULL then
1069: delete from pa_expenditure_comments ec
1070: where ( ec.rowid )
1071: in ( select ec1.rowid
1072: from pa_expenditure_items_all ei,
1073: pa_expenditure_comments ec1
1074: where ei.expenditure_item_id = ec1.expenditure_item_id
1075: and ei.expenditure_item_date <= p_txn_to_date
1076: and ei.project_id = p_project_id

Line 1083: from pa_expenditure_items_all ei,

1079: else
1080: delete from pa_expenditure_comments ec
1081: where ( ec.rowid )
1082: in ( select ec1.rowid
1083: from pa_expenditure_items_all ei,
1084: pa_expenditure_comments ec1
1085: where ei.expenditure_item_id = ec1.expenditure_item_id
1086: and ei.project_id = p_project_id
1087: and rownum <= p_commit_size

Line 1181: from pa_expenditure_items_all ei,

1177: l_fetch_complete BOOLEAN := FALSE;
1178:
1179: cursor c_open_exp_adj is
1180: Select eia1.rowid
1181: from pa_expenditure_items_all ei,
1182: pa_expend_item_adj_activities eia1
1183: where ei.expenditure_item_date <= p_txn_to_date
1184: and ei.expenditure_item_id = eia1.expenditure_item_id
1185: and ei.project_id = p_project_id;

Line 1189: from pa_expenditure_items_all ei,

1185: and ei.project_id = p_project_id;
1186:
1187: cursor c_close_exp_adj is
1188: Select eia1.rowid
1189: from pa_expenditure_items_all ei,
1190: pa_expend_item_adj_activities eia1
1191: where ei.expenditure_item_id = eia1.expenditure_item_id
1192: and ei.project_id = p_project_id;
1193:

Line 1293: from pa_expenditure_items_all ei,

1289:
1290: l_NoOfRecordsDel := SQL%ROWCOUNT;
1291: /*s22 start of comment for performance changes
1292: ( select eia1.rowid
1293: from pa_expenditure_items_all ei,
1294: pa_expend_item_adj_activities eia1
1295: where ei.expenditure_item_date <= p_txn_to_date
1296: and ei.expenditure_item_id = eia1.expenditure_item_id
1297: and ei.project_id = p_project_id

Line 1342: from pa_expenditure_items_all ei,

1338: p_project_id
1339: from pa_expend_item_adj_activities eia
1340: where (eia.rowid ) in
1341: ( select eia1.rowid
1342: from pa_expenditure_items_all ei,
1343: pa_expend_item_adj_activities eia1
1344: where ei.expenditure_item_id = eia1.expenditure_item_id
1345: and ei.project_id = p_project_id
1346: and rownum < p_commit_size

Line 1380: from pa_expenditure_items_all ei,

1376: if p_txn_to_date is NOT NULL then
1377: delete from pa_expend_item_adj_activities eia
1378: where (eia.rowid ) in
1379: ( select eia1.rowid
1380: from pa_expenditure_items_all ei,
1381: pa_expend_item_adj_activities eia1
1382: where ei.expenditure_item_date <= p_txn_to_date
1383: and ei.expenditure_item_id = eia1.expenditure_item_id
1384: and ei.project_id = p_project_id

Line 1392: from pa_expenditure_items_all ei,

1388: else
1389: delete from pa_expend_item_adj_activities eia
1390: where (eia.rowid ) in
1391: ( select eia1.rowid
1392: from pa_expenditure_items_all ei,
1393: pa_expend_item_adj_activities eia1
1394: where ei.expenditure_item_id = eia1.expenditure_item_id
1395: and ei.project_id = p_project_id
1396: and rownum < p_commit_size

Line 2340: select rowid,expenditure_item_id from pa_expenditure_items_all ei

2336: l_exp_item_id_tab_empty PA_PLSQL_DATATYPES.IdTabTyp;
2337: l_request_id NUMBER;
2338:
2339: cursor c_exp_open_projects is
2340: select rowid,expenditure_item_id from pa_expenditure_items_all ei
2341: where ei.expenditure_item_date <= p_txn_to_date
2342: and ei.project_id = p_project_id;
2343:
2344: cursor c_exp_close_projects is

Line 2345: select rowid,expenditure_item_id from pa_expenditure_items_all ei

2341: where ei.expenditure_item_date <= p_txn_to_date
2342: and ei.project_id = p_project_id;
2343:
2344: cursor c_exp_close_projects is
2345: select rowid,expenditure_item_id from pa_expenditure_items_all ei
2346: where ei.project_id = p_project_id;
2347:
2348: begin
2349:

Line 2801: from pa_expenditure_items_all ei

2797: ei.document_payment_id, -- R12 Change
2798: ei.vendor_id, -- R12 Change
2799: ei.document_type, -- R12 Change
2800: ei.document_distribution_type -- R12 Change
2801: from pa_expenditure_items_all ei
2802: where ei.rowid = l_ei_rowid_tab(exp_ind);
2803: l_NoOfRecordsIns := SQL%ROWCOUNT ;
2804: end if;
2805:

Line 2854: from pa_expenditure_items_all ei

2850: 'SOURCE PURGED',
2851: 'PURGE PROCESS',
2852: g_user,
2853: l_request_id
2854: from pa_expenditure_items_all ei
2855: where ei.transferred_from_exp_item_id = l_exp_item_id_tab(exp_ind)
2856: and ei.transferred_from_exp_item_id is not null
2857: and not exists ( select pp.project_id
2858: from pa_purge_projects pp

Line 2863: update pa_expenditure_items_all ei

2859: where pp.project_id = ei.project_id
2860: and pp.purge_batch_id = p_purge_batch_id ) ;
2861:
2862: FORALL exp_ind IN l_exp_item_id_tab.FIRST .. l_exp_item_id_tab.LAST
2863: update pa_expenditure_items_all ei
2864: set ei.transferred_from_exp_item_id = NULL
2865: where ei.transferred_from_exp_item_id = l_exp_item_id_tab(exp_ind)
2866: and ei.transferred_from_exp_item_id is not null
2867: and not exists ( select pp.project_id

Line 2885: x_err_stage := 'PA_ExpenditureItems: Before deleting records from pa_expenditure_items_all';

2881: -- selected because if archive option is selected the the records
2882: -- being purged will be those records which are already archived.
2883: -- table and
2884:
2885: x_err_stage := 'PA_ExpenditureItems: Before deleting records from pa_expenditure_items_all';
2886: FORALL exp_ind IN l_ei_rowid_tab.FIRST .. l_ei_rowid_tab.LAST
2887: DELETE FROM PA_EXPENDITURE_ITEMS_ALL EI
2888: WHERE EI.ROWID = l_ei_rowid_tab(exp_ind);
2889:

Line 2887: DELETE FROM PA_EXPENDITURE_ITEMS_ALL EI

2883: -- table and
2884:
2885: x_err_stage := 'PA_ExpenditureItems: Before deleting records from pa_expenditure_items_all';
2886: FORALL exp_ind IN l_ei_rowid_tab.FIRST .. l_ei_rowid_tab.LAST
2887: DELETE FROM PA_EXPENDITURE_ITEMS_ALL EI
2888: WHERE EI.ROWID = l_ei_rowid_tab(exp_ind);
2889:
2890: l_NoOfRecordsDel := SQL%ROWCOUNT;
2891: l_MRC_NoOfRecordsDel := pa_utils2.MRC_row_count;

Line 3009: from pa_expenditure_items_all ei

3005: 'SOURCE PURGED',
3006: 'PURGE PROCESS',
3007: g_user,
3008: l_request_id
3009: from pa_expenditure_items_all ei
3010: where ei.transferred_from_exp_item_id in ( select ei1.expenditure_item_id
3011: from pa_expenditure_items_all ei1
3012: where ei1.expenditure_item_date <= p_txn_to_date
3013: and ei1.project_id = p_project_id )

Line 3011: from pa_expenditure_items_all ei1

3007: g_user,
3008: l_request_id
3009: from pa_expenditure_items_all ei
3010: where ei.transferred_from_exp_item_id in ( select ei1.expenditure_item_id
3011: from pa_expenditure_items_all ei1
3012: where ei1.expenditure_item_date <= p_txn_to_date
3013: and ei1.project_id = p_project_id )
3014: and ei.transferred_from_exp_item_id is not null
3015: and rownum < l_commit_size

Line 3043: from pa_tasks t,pa_expenditure_items_all ei

3039: 'SOURCE PURGED',
3040: 'PURGE PROCESS',
3041: g_user,
3042: l_request_id
3043: from pa_tasks t,pa_expenditure_items_all ei
3044: where ei.transferred_from_exp_item_id in ( select ei1.expenditure_item_id
3045: from pa_expenditure_items_all ei1,
3046: pa_tasks t1
3047: where ei1.task_id = t1.task_id

Line 3045: from pa_expenditure_items_all ei1,

3041: g_user,
3042: l_request_id
3043: from pa_tasks t,pa_expenditure_items_all ei
3044: where ei.transferred_from_exp_item_id in ( select ei1.expenditure_item_id
3045: from pa_expenditure_items_all ei1,
3046: pa_tasks t1
3047: where ei1.task_id = t1.task_id
3048: and t1.project_id = p_project_id )
3049: and ei.task_id = t.task_id

Line 3446: from pa_expenditure_items_all ei

3442: ei.posted_project_burdened_cost,
3443: ei.posted_projfunc_burdened_cost,
3444: ei.posted_acct_burdened_cost,
3445: ei.adjustment_type
3446: from pa_expenditure_items_all ei
3447: where ei.expenditure_item_id in ( select ei1.transferred_from_exp_item_id
3448: from Pa_Expend_item_Adj_Activities eia,
3449: pa_expenditure_items_all ei1
3450: where ei1.expenditure_item_id = eia.expenditure_item_id

Line 3449: pa_expenditure_items_all ei1

3445: ei.adjustment_type
3446: from pa_expenditure_items_all ei
3447: where ei.expenditure_item_id in ( select ei1.transferred_from_exp_item_id
3448: from Pa_Expend_item_Adj_Activities eia,
3449: pa_expenditure_items_all ei1
3450: where ei1.expenditure_item_id = eia.expenditure_item_id
3451: and eia.request_id = l_request_id
3452: and eia.exception_activity_code= 'SOURCE PURGED'
3453: and ei1.transferred_from_exp_item_id is not null ) ;

Line 3460: x_err_stage := 'PA_ExpItemsSrcPurge: Deleting records into pa_expenditure_items_all';

3456: l_NoOfRecordsIns := SQL%ROWCOUNT ;
3457:
3458: end if ;
3459:
3460: x_err_stage := 'PA_ExpItemsSrcPurge: Deleting records into pa_expenditure_items_all';
3461: delete from pa_expenditure_items_all ei
3462: where ei.expenditure_item_id in ( select ei1.transferred_from_exp_item_id
3463: from Pa_Expend_item_Adj_Activities eia,
3464: pa_expenditure_items_all ei1

Line 3461: delete from pa_expenditure_items_all ei

3457:
3458: end if ;
3459:
3460: x_err_stage := 'PA_ExpItemsSrcPurge: Deleting records into pa_expenditure_items_all';
3461: delete from pa_expenditure_items_all ei
3462: where ei.expenditure_item_id in ( select ei1.transferred_from_exp_item_id
3463: from Pa_Expend_item_Adj_Activities eia,
3464: pa_expenditure_items_all ei1
3465: where ei1.expenditure_item_id = eia.expenditure_item_id

Line 3464: pa_expenditure_items_all ei1

3460: x_err_stage := 'PA_ExpItemsSrcPurge: Deleting records into pa_expenditure_items_all';
3461: delete from pa_expenditure_items_all ei
3462: where ei.expenditure_item_id in ( select ei1.transferred_from_exp_item_id
3463: from Pa_Expend_item_Adj_Activities eia,
3464: pa_expenditure_items_all ei1
3465: where ei1.expenditure_item_id = eia.expenditure_item_id
3466: and eia.request_id = l_request_id
3467: and eia.exception_activity_code= 'SOURCE PURGED'
3468: and ei1.transferred_from_exp_item_id is not null ) ;

Line 3475: update pa_expenditure_items_all ei

3471: l_NoOfRecordsDel := SQL%ROWCOUNT ;
3472: */
3473:
3474: x_err_stage := 'PA_ExpItemsSrcPurge: Deleting the links between expenditure items' ;
3475: update pa_expenditure_items_all ei
3476: set ei.transferred_from_exp_item_id = NULL
3477: where ei.expenditure_item_id in ( select eia.expenditure_item_id
3478: from Pa_Expend_item_Adj_Activities eia
3479: where eia.request_id = l_request_id

Line 3545: from pa_expenditure_items_all ei

3541: l_fetch_complete BOOLEAN:= FALSE;
3542:
3543: cursor c_exp_open_lines is
3544: select ei.transferred_from_exp_item_id
3545: from pa_expenditure_items_all ei
3546: where ei.expenditure_item_date <= p_txn_to_date
3547: and ei.transferred_from_exp_item_id is not null
3548: and ei.project_id = p_project_id;
3549:

Line 3552: from pa_expenditure_items_all ei

3548: and ei.project_id = p_project_id;
3549:
3550: cursor c_exp_close_lines is
3551: select ei.transferred_from_exp_item_id
3552: from pa_expenditure_items_all ei
3553: where ei.transferred_from_exp_item_id is not null
3554: and ei.project_id = p_project_id;
3555:
3556: l_exp_item_id_tab PA_PLSQL_DATATYPES.IdTabTyp;

Line 3625: from pa_expenditure_items_all ei

3621: 'DESTINATION PURGED',
3622: 'PURGE PROCESS',
3623: g_user,
3624: l_Request_Id
3625: from pa_expenditure_items_all ei
3626: where ei.expenditure_item_id = l_exp_item_id_tab(l_exp_ind)
3627: /* in ( select ei1.transferred_from_exp_item_id
3628: from pa_expenditure_items_all ei1
3629: where ei1.expenditure_item_date <= p_txn_to_date

Line 3628: from pa_expenditure_items_all ei1

3624: l_Request_Id
3625: from pa_expenditure_items_all ei
3626: where ei.expenditure_item_id = l_exp_item_id_tab(l_exp_ind)
3627: /* in ( select ei1.transferred_from_exp_item_id
3628: from pa_expenditure_items_all ei1
3629: where ei1.expenditure_item_date <= p_txn_to_date
3630: and ei1.transferred_from_exp_item_id is not null
3631: and ei1.project_id = p_project_id )
3632: and rownum < l_commit_size */

Line 3985: from pa_expenditure_items_all ei

3981: where (x.rowid ) in
3982: ( select x1.rowid
3983: from pa_expenditures_all x1
3984: where not exists ( select ei.expenditure_id
3985: from pa_expenditure_items_all ei
3986: where ei.expenditure_id = x1.expenditure_id)
3987: and x1.expenditure_status_code = 'APPROVED'
3988: and rownum < l_commit_size
3989: ) ;

Line 4024: from pa_expenditure_items_all ei

4020: where (x.rowid ) in
4021: ( select x1.rowid
4022: from pa_expenditures_all x1
4023: where not exists ( select ei.expenditure_id
4024: from pa_expenditure_items_all ei
4025: where ei.expenditure_id = x1.expenditure_id)
4026: and x1.expenditure_status_code = 'APPROVED'
4027: and rownum < l_commit_size
4028: ) ;