invoices to payment

4 05 2017

SELECT aca.check_number “Document Number”,
asa.segment1 “Supplier Number”,
asa.vendor_name “Supplier Name”,
aca.STATUS_LOOKUP_CODE “Payment Reconcilation Status”,
aca.CLEARED_AMOUNT “Payment Amount”,
aca.CURRENCY_CODE “Currency”,
aca.CLEARED_DATE “Payment Date”,
aia.invoice_num,
aia.invoice_amount,
AP_INVOICES_PKG.GET_APPROVAL_STATUS (aia.INVOICE_ID,
aia.INVOICE_AMOUNT,
aia.PAYMENT_STATUS_FLAG,
aia.INVOICE_TYPE_LOOKUP_CODE)
“Invoice Acct Status”,batch_id
FROM ap_checks_all aca,
ap_invoice_payments_all aipa,
ap_invoices_all aia,
ap_suppliers asa
WHERE aca.check_id = aipa.check_id
AND aipa.invoice_id = aia.invoice_id
AND aia.vendor_id = asa.vendor_id
AND aipa.ACCRUAL_POSTED_FLAG = ‘N’
AND POSTED_FLAG = ‘N’
— and aca.check_number =’7221646′
AND TRUNC (aca.CLEARED_DATE) BETWEEN ’01-JAN-2017′ AND ’30-APR-2017′
ORDER BY check_number;

Advertisements

Actions

Information

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s




%d bloggers like this: