DBA Data[Home] [Help]

APPS.JAI_AP_TDS_ETDS_PKG dependencies on AP_INVOICE_DISTRIBUTIONS_ALL

Line 512: FROM ap_invoice_distributions_all

508: SELECT SUM(application_amount)
509: FROM jai_ap_tds_prepayments jatp
510: WHERE invoice_id = p_invoice_id
511: AND (SELECT accounting_date
512: FROM ap_invoice_distributions_all
513: WHERE invoice_distribution_id = jatp.invoice_distribution_id)
514: <=
515: (SELECT accounting_date
516: FROM ap_invoice_distributions_all

Line 516: FROM ap_invoice_distributions_all

512: FROM ap_invoice_distributions_all
513: WHERE invoice_distribution_id = jatp.invoice_distribution_id)
514: <=
515: (SELECT accounting_date
516: FROM ap_invoice_distributions_all
517: WHERE invoice_distribution_id IN (SELECT prepay_distribution_id
518: FROM ap_invoice_distributions_all
519: WHERE invoice_distribution_id = jatp.invoice_distribution_id_prepay
520: )

Line 518: FROM ap_invoice_distributions_all

514: <=
515: (SELECT accounting_date
516: FROM ap_invoice_distributions_all
517: WHERE invoice_distribution_id IN (SELECT prepay_distribution_id
518: FROM ap_invoice_distributions_all
519: WHERE invoice_distribution_id = jatp.invoice_distribution_id_prepay
520: )
521: );
522: CURSOR c_get_applied_amt (p_invoice_id IN NUMBER)

Line 527: FROM ap_invoice_distributions_all

523: IS
524: SELECT SUM(application_amount)
525: FROM jai_ap_tds_prepayments jatp
526: WHERE invoice_id IN (SELECT invoice_id
527: FROM ap_invoice_distributions_all
528: WHERE prepay_distribution_id IN (SELECT invoice_distribution_id
529: FROM ap_invoice_distributions_all
530: WHERE invoice_id = p_invoice_id
531: )

Line 529: FROM ap_invoice_distributions_all

525: FROM jai_ap_tds_prepayments jatp
526: WHERE invoice_id IN (SELECT invoice_id
527: FROM ap_invoice_distributions_all
528: WHERE prepay_distribution_id IN (SELECT invoice_distribution_id
529: FROM ap_invoice_distributions_all
530: WHERE invoice_id = p_invoice_id
531: )
532: )
533: AND (SELECT accounting_date

Line 534: FROM ap_invoice_distributions_all

530: WHERE invoice_id = p_invoice_id
531: )
532: )
533: AND (SELECT accounting_date
534: FROM ap_invoice_distributions_all
535: WHERE invoice_distribution_id = jatp.invoice_distribution_id)
536: >
537: (SELECT accounting_date
538: FROM ap_invoice_distributions_all

Line 538: FROM ap_invoice_distributions_all

534: FROM ap_invoice_distributions_all
535: WHERE invoice_distribution_id = jatp.invoice_distribution_id)
536: >
537: (SELECT accounting_date
538: FROM ap_invoice_distributions_all
539: WHERE invoice_distribution_id IN (SELECT prepay_distribution_id
540: FROM ap_invoice_distributions_all
541: WHERE invoice_distribution_id = jatp.invoice_distribution_id_prepay
542: )

Line 540: FROM ap_invoice_distributions_all

536: >
537: (SELECT accounting_date
538: FROM ap_invoice_distributions_all
539: WHERE invoice_distribution_id IN (SELECT prepay_distribution_id
540: FROM ap_invoice_distributions_all
541: WHERE invoice_distribution_id = jatp.invoice_distribution_id_prepay
542: )
543: );
544: CURSOR c_get_remaining_amt (p_invoice_id IN NUMBER)

Line 547: FROM ap_invoice_distributions_all

543: );
544: CURSOR c_get_remaining_amt (p_invoice_id IN NUMBER)
545: IS
546: SELECT sum(prepay_amount_remaining)
547: FROM ap_invoice_distributions_all
548: WHERE invoice_id = p_invoice_id;
549: CURSOR c_threshold_tran_inv (p_threshold_grp_id IN NUMBER)
550: IS
551: SELECT tds_invoice_id, tds_check_id, tds_tax_id, tds_amount

Line 631: FROM ap_invoice_distributions_all a, ap_invoice_distributions_all b

627: \*added by csahoo for bug # 6158875, END*\
628:
629: CURSOR c_prepay_invoice_id(p_tds_invoice_id IN NUMBER) IS
630: SELECT b.invoice_id prepay_invoice_id
631: FROM ap_invoice_distributions_all a, ap_invoice_distributions_all b
632: WHERE a.invoice_id = p_tds_invoice_id
633: AND a.prepay_distribution_id IS NOT NULL
634: AND (a.reversal_flag IS NULL OR a.reversal_flag = 'N') --rchandan for bug#4428980
635: AND b.invoice_distribution_id = a.prepay_distribution_id;

Line 886: ap_invoice_distributions_all aida,

882: sysdate,
883: fnd_global.user_id,
884: sysdate
885: FROM ap_invoices_all aia,
886: ap_invoice_distributions_all aida,
887: jai_ap_tds_inv_taxes jatit,
888: JAI_AP_TDS_VENDOR_HDRS jte,
889: JAI_CMN_TAXES_ALL jitc
890: WHERE aia.invoice_id = jatit.invoice_id

Line 982: ap_invoice_distributions_all aida, jai_ap_tds_vendor_hdrs jte

978: sysdate,
979: fnd_global.user_id,
980: sysdate
981: from jai_cmn_taxes_all a, ap_invoices_all base_invoices, po_vendor_sites_all povs, \* Added by Avanija for FVU3.6 *\
982: ap_invoice_distributions_all aida, jai_ap_tds_vendor_hdrs jte
983: where jte.vendor_id = base_invoices.vendor_id
984: \* FVU3.6 -start *\
985: and povs.vendor_id = jte.vendor_id
986: and povs.vendor_site_id = jte.vendor_site_id

Line 1055: ap_invoice_distributions_all aida, jai_ap_tds_vendor_hdrs jte, po_vendor_sites_all povs

1051: sysdate,
1052: fnd_global.user_id,
1053: sysdate
1054: from ap_invoices_all base_invoices,
1055: ap_invoice_distributions_all aida, jai_ap_tds_vendor_hdrs jte, po_vendor_sites_all povs
1056: where jte.vendor_id = base_invoices.vendor_id
1057: and jte.vendor_site_id = base_invoices.vendor_site_id--Added by Zhhou for bug#15962641 20121205
1058: --Changed by Zhiwei for Bug#15840480 FVU3.6 begin
1059: -----------------------------------------------------

Line 1182: ap_invoice_distributions_all aida,

1178: sysdate,
1179: fnd_global.user_id,
1180: sysdate
1181: FROM ap_invoices_all aia,
1182: ap_invoice_distributions_all aida,
1183: jai_ap_tds_inv_taxes jatit,
1184: JAI_AP_TDS_VENDOR_HDRS jte,
1185: JAI_CMN_TAXES_ALL jitc
1186: WHERE aia.invoice_id = jatit.invoice_id

Line 1282: ap_invoice_distributions_all aida,

1278: sysdate,
1279: fnd_global.user_id,
1280: sysdate
1281: FROM ap_invoices_all aia,
1282: ap_invoice_distributions_all aida,
1283: jai_ap_tds_inv_taxes jatit,
1284: JAI_AP_TDS_VENDOR_HDRS jte,
1285: JAI_CMN_TAXES_ALL jitc
1286: WHERE aia.invoice_id = jatit.invoice_id

Line 1556: from ap_invoice_distributions_all

1552:
1553: IF dtl.inv_type = 'PREPAYMENT' THEN
1554: v_statement_id := '3g';
1555: select sum(amount) - sum( nvl(prepay_amount_remaining, amount)) INTO v_prepayment_amount_applied
1556: from ap_invoice_distributions_all
1557: where invoice_id = dtl.base_invoice_id
1558: and attribute1 = dtl.tds_tax_id;
1559: END IF;
1560:

Line 1763: FROM ap_invoice_distributions_all

1759: SELECT SUM(application_amount)
1760: FROM jai_ap_tds_prepayments jatp
1761: WHERE invoice_id = p_invoice_id
1762: AND (SELECT accounting_date
1763: FROM ap_invoice_distributions_all
1764: WHERE invoice_distribution_id = jatp.invoice_distribution_id)
1765: <=
1766: (SELECT accounting_date
1767: FROM ap_invoice_distributions_all

Line 1767: FROM ap_invoice_distributions_all

1763: FROM ap_invoice_distributions_all
1764: WHERE invoice_distribution_id = jatp.invoice_distribution_id)
1765: <=
1766: (SELECT accounting_date
1767: FROM ap_invoice_distributions_all
1768: WHERE invoice_distribution_id IN (SELECT prepay_distribution_id
1769: FROM ap_invoice_distributions_all
1770: WHERE invoice_distribution_id = jatp.invoice_distribution_id_prepay
1771: )

Line 1769: FROM ap_invoice_distributions_all

1765: <=
1766: (SELECT accounting_date
1767: FROM ap_invoice_distributions_all
1768: WHERE invoice_distribution_id IN (SELECT prepay_distribution_id
1769: FROM ap_invoice_distributions_all
1770: WHERE invoice_distribution_id = jatp.invoice_distribution_id_prepay
1771: )
1772: );
1773: CURSOR c_get_applied_amt (p_invoice_id IN NUMBER)

Line 1778: FROM ap_invoice_distributions_all

1774: IS
1775: SELECT SUM(application_amount)
1776: FROM jai_ap_tds_prepayments jatp
1777: WHERE invoice_id IN (SELECT invoice_id
1778: FROM ap_invoice_distributions_all
1779: WHERE prepay_distribution_id IN (SELECT invoice_distribution_id
1780: FROM ap_invoice_distributions_all
1781: WHERE invoice_id = p_invoice_id
1782: )

Line 1780: FROM ap_invoice_distributions_all

1776: FROM jai_ap_tds_prepayments jatp
1777: WHERE invoice_id IN (SELECT invoice_id
1778: FROM ap_invoice_distributions_all
1779: WHERE prepay_distribution_id IN (SELECT invoice_distribution_id
1780: FROM ap_invoice_distributions_all
1781: WHERE invoice_id = p_invoice_id
1782: )
1783: )
1784: AND (SELECT accounting_date

Line 1785: FROM ap_invoice_distributions_all

1781: WHERE invoice_id = p_invoice_id
1782: )
1783: )
1784: AND (SELECT accounting_date
1785: FROM ap_invoice_distributions_all
1786: WHERE invoice_distribution_id = jatp.invoice_distribution_id)
1787: >
1788: (SELECT accounting_date
1789: FROM ap_invoice_distributions_all

Line 1789: FROM ap_invoice_distributions_all

1785: FROM ap_invoice_distributions_all
1786: WHERE invoice_distribution_id = jatp.invoice_distribution_id)
1787: >
1788: (SELECT accounting_date
1789: FROM ap_invoice_distributions_all
1790: WHERE invoice_distribution_id IN (SELECT prepay_distribution_id
1791: FROM ap_invoice_distributions_all
1792: WHERE invoice_distribution_id = jatp.invoice_distribution_id_prepay
1793: )

Line 1791: FROM ap_invoice_distributions_all

1787: >
1788: (SELECT accounting_date
1789: FROM ap_invoice_distributions_all
1790: WHERE invoice_distribution_id IN (SELECT prepay_distribution_id
1791: FROM ap_invoice_distributions_all
1792: WHERE invoice_distribution_id = jatp.invoice_distribution_id_prepay
1793: )
1794: );
1795: CURSOR c_get_remaining_amt (p_invoice_id IN NUMBER)

Line 1798: FROM ap_invoice_distributions_all

1794: );
1795: CURSOR c_get_remaining_amt (p_invoice_id IN NUMBER)
1796: IS
1797: SELECT sum(prepay_amount_remaining)
1798: FROM ap_invoice_distributions_all
1799: WHERE invoice_id = p_invoice_id;
1800: CURSOR c_threshold_tran_inv (p_threshold_grp_id IN NUMBER)
1801: IS
1802: SELECT tds_invoice_id, tds_check_id, tds_tax_id, tds_amount

Line 1882: FROM ap_invoice_distributions_all a, ap_invoice_distributions_all b

1878: /*added by csahoo for bug # 6158875, END*/
1879:
1880: CURSOR c_prepay_invoice_id(p_tds_invoice_id IN NUMBER) IS
1881: SELECT b.invoice_id prepay_invoice_id
1882: FROM ap_invoice_distributions_all a, ap_invoice_distributions_all b
1883: WHERE a.invoice_id = p_tds_invoice_id
1884: AND a.prepay_distribution_id IS NOT NULL
1885: AND (a.reversal_flag IS NULL OR a.reversal_flag = 'N') --rchandan for bug#4428980
1886: AND b.invoice_distribution_id = a.prepay_distribution_id;

Line 2261: from ap_invoice_distributions_all

2257:
2258: IF dtl.inv_type = 'PREPAYMENT' THEN
2259: v_statement_id := '3g';
2260: select sum(amount) - sum( nvl(prepay_amount_remaining, amount)) INTO v_prepayment_amount_applied
2261: from ap_invoice_distributions_all
2262: where invoice_id = dtl.base_invoice_id
2263: and attribute1 = dtl.tds_tax_id;
2264: END IF;
2265:

Line 5325: CURSOR c_base_inv_gl_date(p_invoice_id IN NUMBER, p_tax_id IN NUMBER,p_line_type ap_invoice_distributions_all.line_type_lookup_code%type) IS

5321: WHERE invoice_id = p_base_invoice_id;
5322: /*Bug 10188600-End*/
5323:
5324:
5325: CURSOR c_base_inv_gl_date(p_invoice_id IN NUMBER, p_tax_id IN NUMBER,p_line_type ap_invoice_distributions_all.line_type_lookup_code%type) IS
5326: SELECT accounting_date
5327: FROM ap_invoice_distributions_all
5328: WHERE invoice_id = p_invoice_id
5329: AND line_type_lookup_code = p_line_type

Line 5327: FROM ap_invoice_distributions_all

5323:
5324:
5325: CURSOR c_base_inv_gl_date(p_invoice_id IN NUMBER, p_tax_id IN NUMBER,p_line_type ap_invoice_distributions_all.line_type_lookup_code%type) IS
5326: SELECT accounting_date
5327: FROM ap_invoice_distributions_all
5328: WHERE invoice_id = p_invoice_id
5329: AND line_type_lookup_code = p_line_type
5330: AND global_attribute1 = to_char(p_tax_id);--rchandan for bug#4333488
5331:

Line 6233: be populated in the attribute columns of ap_invoice_distributions_all table

6229:
6230: 7. 8/05/2005 rchandan for bug#4333488. Version 116.1
6231: The Invoice Distribution DFF is eliminated and a new global DFF is used to
6232: maintain the functionality. From now the TDS tax, WCT tax and ESSI will not
6233: be populated in the attribute columns of ap_invoice_distributions_all table
6234: instead these will be populated in the global attribute columns. So the code changes are
6235: made accordingly.Both Payment and India distributions DFF elimintion is taken care of in
6236: the same version.
6237: