DBA Data[Home] [Help]

APPS.PJM_TRANSFER_CHARGES_PKG dependencies on AP_INVOICE_DISTRIBUTIONS_ALL

Line 375: FROM AP_Invoice_Distributions_all

371: , Base_Amount
372: , PO_Distribution_Id
373: , RCV_Transaction_Id
374: , Line_Type_Lookup_Code
375: FROM AP_Invoice_Distributions_all
376: WHERE LINE_TYPE_LOOKUP_CODE IN ('IPV', 'ERV', 'TIPV', 'TERV', 'TRV')
377: AND (Accounting_Date between NVL(l_Start_Date, to_date('0001-01-01', 'YYYY-MM-DD')) and NVL(l_End_Date, to_date('9999-01-01', 'YYYY-MM-DD')))
378: AND PA_ADDITION_FLAG in ('E', 'M', 'N')
379: AND POSTED_FLAG = 'Y'

Line 439: , NVL(P.PO_Distribution_Id,(SELECT PO_Distribution_Id FROM AP_Invoice_Distributions_all P1

435: , C.Dist_Code_Combination_Id
436: , C.Accts_Pay_Code_Combination_Id
437: , C.Amount
438: , C.Base_Amount
439: , NVL(P.PO_Distribution_Id,(SELECT PO_Distribution_Id FROM AP_Invoice_Distributions_all P1
440: WHERE P1.invoice_distribution_id = P.charge_applicable_to_dist_id)) PO_Distribution_Id -- bugfix 7482789
441: , C.RCV_Transaction_Id
442: , C.Line_Type_Lookup_Code
443: FROM AP_Invoice_Distributions_all C, AP_Invoice_Distributions_all P

Line 443: FROM AP_Invoice_Distributions_all C, AP_Invoice_Distributions_all P

439: , NVL(P.PO_Distribution_Id,(SELECT PO_Distribution_Id FROM AP_Invoice_Distributions_all P1
440: WHERE P1.invoice_distribution_id = P.charge_applicable_to_dist_id)) PO_Distribution_Id -- bugfix 7482789
441: , C.RCV_Transaction_Id
442: , C.Line_Type_Lookup_Code
443: FROM AP_Invoice_Distributions_all C, AP_Invoice_Distributions_all P
444: WHERE C.LINE_TYPE_LOOKUP_CODE IN ('FREIGHT','MISCELLANEOUS','NONREC_TAX') -- bugfix 7482789
445: AND C.PA_ADDITION_FLAG in ('E', 'M', 'N')
446: AND C.POSTED_FLAG = 'Y'
447: AND (C.Accounting_Date between NVL(l_Start_Date, to_date('0001-01-01', 'YYYY-MM-DD')) and NVL(l_End_Date, to_date('9999-01-01', 'YYYY-MM-DD')))

Line 511: FROM AP_Invoice_Distributions_all

507: , Base_Amount
508: , PO_Distribution_Id
509: , RCV_Transaction_Id
510: , Line_Type_Lookup_Code
511: FROM AP_Invoice_Distributions_all
512: WHERE LINE_TYPE_LOOKUP_CODE IN ('IPV', 'ERV', 'TIPV', 'TERV', 'TRV')
513: AND PA_ADDITION_FLAG in ('E', 'M', 'N')
514: AND POSTED_FLAG = 'Y'
515: ) DIST,

Line 577: , NVL(P.PO_Distribution_Id,(SELECT PO_Distribution_Id FROM AP_Invoice_Distributions_all P1

573: , C.Dist_Code_Combination_Id
574: , C.Accts_Pay_Code_Combination_Id
575: , C.Amount
576: , C.Base_Amount
577: , NVL(P.PO_Distribution_Id,(SELECT PO_Distribution_Id FROM AP_Invoice_Distributions_all P1
578: WHERE P1.invoice_distribution_id = P.charge_applicable_to_dist_id)) PO_Distribution_Id -- bugfix 7482789
579: , C.RCV_Transaction_Id
580: , C.Line_Type_Lookup_Code
581: FROM AP_Invoice_Distributions_all C, AP_Invoice_Distributions_all P

Line 581: FROM AP_Invoice_Distributions_all C, AP_Invoice_Distributions_all P

577: , NVL(P.PO_Distribution_Id,(SELECT PO_Distribution_Id FROM AP_Invoice_Distributions_all P1
578: WHERE P1.invoice_distribution_id = P.charge_applicable_to_dist_id)) PO_Distribution_Id -- bugfix 7482789
579: , C.RCV_Transaction_Id
580: , C.Line_Type_Lookup_Code
581: FROM AP_Invoice_Distributions_all C, AP_Invoice_Distributions_all P
582: WHERE C.LINE_TYPE_LOOKUP_CODE IN ('FREIGHT','MISCELLANEOUS','NONREC_TAX') -- bugfix 7482789
583: AND C.PA_ADDITION_FLAG in ('E', 'M', 'N')
584: AND C.POSTED_FLAG = 'Y'
585: AND C.charge_applicable_to_dist_id = P.invoice_distribution_id

Line 875: UPDATE AP_Invoice_Distributions_all

871: InvRec.Charge_Amount) , 0) <> 0 ) then
872:
873: PJM_CONC.put_line('...... Charge amount not available, skipping...');
874: -- Mark skipped record to 'G'
875: UPDATE AP_Invoice_Distributions_all
876: SET pa_addition_flag = 'G'
877: WHERE invoice_distribution_id = ( select nvl(related_id, charge_applicable_to_dist_id)
878: from ap_invoice_distributions_all
879: where Invoice_Id = InvRec.Invoice_Id

Line 878: from ap_invoice_distributions_all

874: -- Mark skipped record to 'G'
875: UPDATE AP_Invoice_Distributions_all
876: SET pa_addition_flag = 'G'
877: WHERE invoice_distribution_id = ( select nvl(related_id, charge_applicable_to_dist_id)
878: from ap_invoice_distributions_all
879: where Invoice_Id = InvRec.Invoice_Id
880: and Invoice_Distribution_Id = InvRec.Invoice_Distribution_Id);
881:
882: elsif ( l_Exp_Type is null) then

Line 886: UPDATE AP_Invoice_Distributions_all

882: elsif ( l_Exp_Type is null) then
883:
884: PJM_CONC.put_line('...... Inv Org not setup to transfer charges, skipping...');
885: -- Mark skipped record to 'G'
886: UPDATE AP_Invoice_Distributions_all
887: SET pa_addition_flag = 'G'
888: WHERE invoice_distribution_id = ( select nvl(related_id, charge_applicable_to_dist_id)
889: from ap_invoice_distributions_all
890: where Invoice_Id = InvRec.Invoice_Id

Line 889: from ap_invoice_distributions_all

885: -- Mark skipped record to 'G'
886: UPDATE AP_Invoice_Distributions_all
887: SET pa_addition_flag = 'G'
888: WHERE invoice_distribution_id = ( select nvl(related_id, charge_applicable_to_dist_id)
889: from ap_invoice_distributions_all
890: where Invoice_Id = InvRec.Invoice_Id
891: and Invoice_Distribution_Id = InvRec.Invoice_Distribution_Id);
892:
893: else

Line 1078: AP_Invoice_Distributions_all DIST

1074: , PoRec.wip_resource_id
1075: , InvRec.Org_Id
1076: , l_system_reference
1077: FROM
1078: AP_Invoice_Distributions_all DIST
1079: , PA_Tasks TASK
1080: , HR_Organization_Units ORG
1081: WHERE
1082: DIST.Invoice_Id = InvRec.Invoice_Id

Line 1098: UPDATE AP_Invoice_Distributions_all

1094: PJM_CONC.new_line(1);
1095:
1096: l_progress := 80;
1097:
1098: UPDATE AP_Invoice_Distributions_all
1099: SET Pa_Addition_Flag = 'Y',
1100: Request_Id = l_request_id
1101: WHERE Invoice_Id = InvRec.Invoice_Id
1102: AND Invoice_Distribution_Id = InvRec.Invoice_Distribution_Id;

Line 1309: UPDATE AP_Invoice_Distributions_all

1305: InvRec.Charge_Amount) , 0) <> 0 ) then
1306:
1307: PJM_CONC.put_line('...... Charge amount not available, skipping...');
1308: -- Mark skipped record to 'G'
1309: UPDATE AP_Invoice_Distributions_all
1310: SET pa_addition_flag = 'G'
1311: WHERE invoice_distribution_id = ( select nvl(related_id, charge_applicable_to_dist_id)
1312: from ap_invoice_distributions_all
1313: where Invoice_Id = InvRec.Invoice_Id

Line 1312: from ap_invoice_distributions_all

1308: -- Mark skipped record to 'G'
1309: UPDATE AP_Invoice_Distributions_all
1310: SET pa_addition_flag = 'G'
1311: WHERE invoice_distribution_id = ( select nvl(related_id, charge_applicable_to_dist_id)
1312: from ap_invoice_distributions_all
1313: where Invoice_Id = InvRec.Invoice_Id
1314: and Invoice_Distribution_Id = InvRec.Invoice_Distribution_Id);
1315:
1316: elsif ( l_Exp_Type is null) then

Line 1320: UPDATE AP_Invoice_Distributions_all

1316: elsif ( l_Exp_Type is null) then
1317:
1318: PJM_CONC.put_line('...... Inv Org not setup to transfer charges, skipping...');
1319: -- Mark skipped record to 'G'
1320: UPDATE AP_Invoice_Distributions_all
1321: SET pa_addition_flag = 'G'
1322: WHERE invoice_distribution_id = ( select nvl(related_id, charge_applicable_to_dist_id)
1323: from ap_invoice_distributions_all
1324: where Invoice_Id = InvRec.Invoice_Id

Line 1323: from ap_invoice_distributions_all

1319: -- Mark skipped record to 'G'
1320: UPDATE AP_Invoice_Distributions_all
1321: SET pa_addition_flag = 'G'
1322: WHERE invoice_distribution_id = ( select nvl(related_id, charge_applicable_to_dist_id)
1323: from ap_invoice_distributions_all
1324: where Invoice_Id = InvRec.Invoice_Id
1325: and Invoice_Distribution_Id = InvRec.Invoice_Distribution_Id);
1326:
1327: else

Line 1511: AP_Invoice_Distributions_all DIST

1507: , PoRec.wip_resource_id
1508: , InvRec.Org_Id
1509: , l_system_reference
1510: FROM
1511: AP_Invoice_Distributions_all DIST
1512: , PA_Tasks TASK
1513: , HR_Organization_Units ORG
1514: WHERE
1515: DIST.Invoice_Id = InvRec.Invoice_Id

Line 1531: UPDATE AP_Invoice_Distributions_all

1527: PJM_CONC.new_line(1);
1528:
1529: l_progress := 88;
1530:
1531: UPDATE AP_Invoice_Distributions_all
1532: SET Pa_Addition_Flag = 'Y',
1533: Request_Id = l_request_id
1534: WHERE Invoice_Id = InvRec.Invoice_Id
1535: AND Invoice_Distribution_Id = InvRec.Invoice_Distribution_Id;

Line 1748: UPDATE AP_Invoice_Distributions_all

1744: InvRec.Charge_Amount) , 0) <> 0 ) then
1745:
1746: PJM_CONC.put_line('...... Charge amount not available, skipping...');
1747: -- Mark skipped record to 'G'
1748: UPDATE AP_Invoice_Distributions_all
1749: SET pa_addition_flag = 'G'
1750: WHERE invoice_distribution_id = ( select nvl(related_id, charge_applicable_to_dist_id)
1751: from ap_invoice_distributions_all
1752: where Invoice_Id = InvRec.Invoice_Id

Line 1751: from ap_invoice_distributions_all

1747: -- Mark skipped record to 'G'
1748: UPDATE AP_Invoice_Distributions_all
1749: SET pa_addition_flag = 'G'
1750: WHERE invoice_distribution_id = ( select nvl(related_id, charge_applicable_to_dist_id)
1751: from ap_invoice_distributions_all
1752: where Invoice_Id = InvRec.Invoice_Id
1753: and Invoice_Distribution_Id = InvRec.Invoice_Distribution_Id);
1754:
1755: elsif ( l_Exp_Type is null) then

Line 1759: UPDATE AP_Invoice_Distributions_all

1755: elsif ( l_Exp_Type is null) then
1756:
1757: PJM_CONC.put_line('...... Inv Org not setup to transfer charges, skipping...');
1758: -- Mark skipped record to 'G'
1759: UPDATE AP_Invoice_Distributions_all
1760: SET pa_addition_flag = 'G'
1761: WHERE invoice_distribution_id = ( select nvl(related_id, charge_applicable_to_dist_id)
1762: from ap_invoice_distributions_all
1763: where Invoice_Id = InvRec.Invoice_Id

Line 1762: from ap_invoice_distributions_all

1758: -- Mark skipped record to 'G'
1759: UPDATE AP_Invoice_Distributions_all
1760: SET pa_addition_flag = 'G'
1761: WHERE invoice_distribution_id = ( select nvl(related_id, charge_applicable_to_dist_id)
1762: from ap_invoice_distributions_all
1763: where Invoice_Id = InvRec.Invoice_Id
1764: and Invoice_Distribution_Id = InvRec.Invoice_Distribution_Id);
1765:
1766: else -- Start proecess

Line 1950: AP_Invoice_Distributions_all DIST

1946: , PoRec.Wip_Resource_Id
1947: , InvRec.Org_Id
1948: , l_system_reference
1949: FROM
1950: AP_Invoice_Distributions_all DIST
1951: , PA_Tasks TASK
1952: , HR_Organization_Units ORG
1953: WHERE
1954: DIST.Invoice_Id = InvRec.Invoice_Id

Line 1970: UPDATE AP_Invoice_Distributions_all

1966: PJM_CONC.new_line(1);
1967:
1968: l_progress := 160;
1969:
1970: UPDATE AP_Invoice_Distributions_all
1971: SET Pa_Addition_Flag = 'Y',
1972: Request_Id = l_request_id
1973: WHERE Invoice_Id = InvRec.Invoice_Id
1974: AND Invoice_Distribution_Id = InvRec.Invoice_Distribution_Id;

Line 2176: UPDATE AP_Invoice_Distributions_all

2172: InvRec.Charge_Amount) , 0) <> 0 ) then
2173:
2174: PJM_CONC.put_line('...... Charge amount not available, skipping...');
2175: -- Mark skipped record to 'G'
2176: UPDATE AP_Invoice_Distributions_all
2177: SET pa_addition_flag = 'G'
2178: WHERE invoice_distribution_id = ( select nvl(related_id, charge_applicable_to_dist_id)
2179: from ap_invoice_distributions_all
2180: where Invoice_Id = InvRec.Invoice_Id

Line 2179: from ap_invoice_distributions_all

2175: -- Mark skipped record to 'G'
2176: UPDATE AP_Invoice_Distributions_all
2177: SET pa_addition_flag = 'G'
2178: WHERE invoice_distribution_id = ( select nvl(related_id, charge_applicable_to_dist_id)
2179: from ap_invoice_distributions_all
2180: where Invoice_Id = InvRec.Invoice_Id
2181: and Invoice_Distribution_Id = InvRec.Invoice_Distribution_Id);
2182:
2183: elsif ( l_Exp_Type is null) then

Line 2187: UPDATE AP_Invoice_Distributions_all

2183: elsif ( l_Exp_Type is null) then
2184:
2185: PJM_CONC.put_line('...... Inv Org not setup to transfer charges, skipping...');
2186: -- Mark skipped record to 'G'
2187: UPDATE AP_Invoice_Distributions_all
2188: SET pa_addition_flag = 'G'
2189: WHERE invoice_distribution_id = ( select nvl(related_id, charge_applicable_to_dist_id)
2190: from ap_invoice_distributions_all
2191: where Invoice_Id = InvRec.Invoice_Id

Line 2190: from ap_invoice_distributions_all

2186: -- Mark skipped record to 'G'
2187: UPDATE AP_Invoice_Distributions_all
2188: SET pa_addition_flag = 'G'
2189: WHERE invoice_distribution_id = ( select nvl(related_id, charge_applicable_to_dist_id)
2190: from ap_invoice_distributions_all
2191: where Invoice_Id = InvRec.Invoice_Id
2192: and Invoice_Distribution_Id = InvRec.Invoice_Distribution_Id);
2193:
2194: else -- Start proecess

Line 2379: AP_Invoice_Distributions_all DIST

2375: , PoRec.Wip_Resource_Id
2376: , InvRec.Org_Id
2377: , l_system_reference
2378: FROM
2379: AP_Invoice_Distributions_all DIST
2380: , PA_Tasks TASK
2381: , HR_Organization_Units ORG
2382: WHERE
2383: DIST.Invoice_Id = InvRec.Invoice_Id

Line 2399: UPDATE AP_Invoice_Distributions_all

2395: PJM_CONC.new_line(1);
2396:
2397: l_progress := 168;
2398:
2399: UPDATE AP_Invoice_Distributions_all
2400: SET Pa_Addition_Flag = 'Y',
2401: Request_Id = l_request_id
2402: WHERE Invoice_Id = InvRec.Invoice_Id
2403: AND Invoice_Distribution_Id = InvRec.Invoice_Distribution_Id;