Search Results prepay_number




Overview

APPS.AP_VIEW_PREPAYS_V is a reporting view in the Oracle E-Business Suite Payables (SQLAP) product family. It consolidates prepayment invoice information with the detail of how each prepayment has been applied, remaining balances, and the associated suppliers, purchase orders, and receiving transactions. The view is registered in the Application Object Library under FND Design Data SQLAP.AP_VIEW_PREPAYS_V, is owned by the APPS schema, and carries a status of VALID in both Oracle EBS 12.1.1 and 12.2.2.

The view is designed primarily for inquiry and reporting rather than transactional processing. It is not referenced by any other database object, meaning no dependent views, packages, or concurrent programs rely on it. Consultants and developers typically use it to answer questions about prepayment consumption: which prepayment invoices remain outstanding, how much has been applied against them, and which purchase order or receipt the prepayment relates to. Because the view exposes the PREPAY_NUMBER column directly, it is a natural starting point for any query originating from a user-supplied prepayment number.

Underlying Base Objects

The view is defined over a combination of Payables, Purchasing, and Receiving objects, mediated by two PL/SQL utility packages. The core invoice data comes from AP_INVOICES_ALL, AP_INVOICE_LINES, and AP_INVOICE_DISTRIBUTIONS. Supplier information is drawn from PO_VENDORS and PO_VENDOR_SITES_ALL, while purchase order context is supplied by PO_HEADERS_ALL. Receiving details originate from RCV_SHIPMENT_HEADERS, RCV_SHIPMENT_LINES, and RCV_TRANSACTIONS.

Two packages contribute derived values. AP_PREPAY_UTILS_PKG supplies the prepayment application logic, including amounts applied and remaining. AP_MATCHING_UTILS_PKG supports matching-related computations. FND_GLOBAL supplies session context such as ORG_ID and SET_OF_BOOKS_ID, enforcing multi-org and ledger security at query time. Because the underlying invoice objects are synonyms to the corresponding AP tables, the view inherits standard Payables security and joins through the operating unit context established by FND_GLOBAL.

Key Columns

Common Use Cases and Queries

The most frequent use case is locating a prepayment by its number and reviewing how much remains unapplied. A typical query filters on PREPAY_NUMBER and ORG_ID:

  • SELECT PREPAY_NUMBER, VENDOR_NAME, PREPAY_AMOUNT_APPLIED, PREPAY_AMOUNT_REMAINING, INVOICE_CURRENCY_CODE FROM APPS.AP_VIEW_PREPAYS_V WHERE PREPAY_NUMBER = :prepay_number AND ORG_ID = :org_id;
  • Open prepayment analysis by supplier: SELECT VENDOR_NAME, VENDOR_NUMBER, PREPAY_NUMBER, PREPAY_AMOUNT_REMAINING FROM APPS.AP_VIEW_PREPAYS_V WHERE PREPAY_AMOUNT_REMAINING > 0 ORDER BY VENDOR_NAME;
  • Prepayments tied to a purchase order: SELECT PREPAY_NUMBER, PO_NUMBER, RECEIPT_NUMBER, PREPAY_AMOUNT_APPLIED FROM APPS.AP_VIEW_PREPAYS_V WHERE PO_NUMBER = :po_number;

Because the view joins invoice, purchase order, and receiving data, it is well suited to reconciliation reports and to integration extracts that require prepayment status alongside supplier and PO context. Queries should always include ORG_ID or rely on FND_GLOBAL session context to respect multi-org security.