When a credit memo is applied to an invoice in Oracle Receivables, the application is stored in AR_RECEIVABLE_APPLICATIONS_ALL with APPLICATION_TYPE = 'CM'. Its PAYMENT_SCHEDULE_ID points to the credit memo’s payment schedule and APPLIED_CUSTOMER_TRX_ID to the invoice. The query below lists, for a credit memo number, every invoice it was applied to with both transaction types, original amounts, the amount applied and what remains due on each.
SQL: credit memo applications to invoices
-- AR credit memos applied to invoices
select
rct.trx_number "INV Number",
ctt_inv.name "Invoice Type",
ps_cm.trx_number "CM/RCPT Number",
ctt_cm.name "CM/Receipt Type",
ps_inv.amount_due_original "INV Amount",
ps_cm.amount_due_original * -1 "CM/RCPT Amount",
app.amount_applied "Amt Applied",
ps_inv.amount_due_remaining "INV Amt Due",
ps_cm.amount_due_remaining *-1 "CM/RCPT Amt Due",
app.receivable_application_id "ID",
app.creation_date,
app.status
from
ar_receivable_applications_all app,
ra_customer_trx_all rct,
ar_payment_schedules_all ps_cm,
ar_payment_schedules_all ps_inv,
ra_cust_trx_types_all ctt_inv,
ra_cust_trx_types_all ctt_cm
where
1 = 1 /*
and app.status = 'APP' */
and app.application_type = 'CM'
and app.applied_customer_trx_id = rct.customer_trx_id
and app.payment_schedule_id = ps_cm.payment_schedule_id
and rct.cust_trx_type_id = ctt_inv.cust_trx_type_id
and ps_cm.cust_trx_type_id = ctt_cm.cust_trx_type_id
and rct.customer_trx_id = ps_inv.customer_trx_id
and ps_cm.trx_number in ('5079644');
Notes
- Replace
'5079644'with the credit memo number, or filter onrct.trx_numberto start from the invoice. - Uncomment the
app.status = 'APP'line to exclude reversed or unapplied rows. - Credit memo amounts are negative in AR_PAYMENT_SCHEDULES_ALL; the query multiplies them by -1 to show positive values.
- Add
app.org_idwhen the same numbers exist in several operating units.
Where are AR credit memo applications stored?
In AR_RECEIVABLE_APPLICATIONS_ALL with APPLICATION_TYPE = ‘CM’. Receipt applications use APPLICATION_TYPE = ‘CASH’.
How do I find the remaining balance of an invoice in Oracle AR?
AR_PAYMENT_SCHEDULES_ALL.AMOUNT_DUE_REMAINING for the invoice’s payment schedule.
Related queries
- Oracle Apps AR Receipt Applications and SLA Details Query
- Oracle EBS Query to Get AR Invoice SLA (Subledger Accounting) Details
- R12 AR Cash Receipt SLA and GL Details Query
- Query to Get AR Invoice SLA and GL Journal Details in Oracle R12
- Query to Find GL Interface (Journal Import) Errors in Oracle R12
- TCA Query: Customer Party Site and Address by Location in Oracle R12
- Query to Find AR Credit Memos Applied to an Invoice in Oracle R12
- PTD Balance from GL Journal Totals in Oracle R12
- Reconcile GL Balances with Journal Totals in Oracle R12
- GL Journal Lines Extract for a Particular Account in Oracle R12
- PTD and YTD Balance Query for a GL Account in Oracle R12
- Query to Find All Expense Report Entry Delegations in Oracle iExpenses
- Query to Find Vacation Rules (Workflow Delegations) in Oracle R12
- View Accounting Query in Oracle Apps R12 (SLA / XLA Tables)
- Query to Get AR Invoice SLA and GL Journal Details in Oracle R12
- Accounting Entries Not Transferred to the General Ledger (SLA to GL Query)
- Query to Find All Public APIs of Oracle Apps Modules
- R12 AR Cash Receipt SLA and GL Details Query
- Oracle Apps AR Receipt Applications and SLA Details Query
- Oracle EBS Query to Get AP Invoice SLA (Subledger Accounting) Details
- Oracle EBS Query to Get AR Invoice SLA (Subledger Accounting) Details
- Oracle AR Remit-To Address Query
- Oracle iExpenses Credit Card Details Query (Cards, Programs and Transactions)
- Query to Get Customer Tax Registration Details in Oracle R12
- Purchase Requisition Vertex Debug XML Query in Oracle EBS
- Purchase Order Vertex Debug XML Query in Oracle EBS
- AP Invoice Vertex Debug XML Query in Oracle EBS
- AR Invoice Vertex Debug XML Query in Oracle EBS
- Query to Find the AP Invoice Approval Workflow Item Key in Oracle Apps
- Query to Find Period Status for Inventory, GL, Purchasing, Payables, Receivables and Fixed Assets
- Oracle Fixed Assets Query: Asset Details with Cost, Depreciation and Net Book Value (NBV)
- Query to Find Sales Orders That Are Shipped but Not Invoiced
- Query to Get Customer Bank Account Details in Oracle R12 (Oracle Payments)
- Query to Get the Description of a GL Code Combination
- Query to Find Purchase Order and AP Invoice Details
- Query to Find AP Invoices Matched to Receipts
- Query to Find Supplier Bank Account Details in Oracle R12
- Query to Find Credit Memos Matched to an AP Invoice
- Query to Find AP Invoices Matched to Multiple Purchase Orders
- AutoInvoice Grouping Columns in RA_INTERFACE_LINES_ALL (OM to AR)
- Query to Find Ship Sets and Fulfillment Sets in Oracle Order Management
