Search Results get_line_reference
Overview
APPS.ARPT_SQL_FUNC_UTIL is a utility package in the Oracle E-Business Suite Receivables (AR) module, classified as a UTIL API and owned by the APPS schema. It is declared with AUTHID CURRENT_USER, meaning its SQL statements execute with the privileges of the invoking user rather than the definer, which makes it suitable for reuse across calling contexts. The package centralizes a broad set of scalar "lookup" functions that derive transactional, financial, and reference attributes for customer transactions. Rather than requiring callers to embed complex queries against Receivables base tables, the package exposes compact PL/SQL functions that return a single value — a flag, an amount, a date, or a reference string — for a given transaction or term.
The package is a well-established component of the Receivables codebase, with a header revision dated 2012 and a footprint spanning 47 documented procedures and functions. Its widespread adoption is evidenced by the fact that it is referenced by 147 other packages, indicating that it serves as a shared low-level utility layer for forms, concurrent programs, and other APIs throughout the Receivables and Advanced Collections stack.
Key Procedures and Functions
- GET_NONMODAL_ROW_EXIST_FLAG — Returns a flag indicating whether a non-modal (non-schedule) row exists for the specified customer transaction and invoicing rule. This is the function the user searched for; it supports revenue recognition and invoicing rule processing. It does not expose a modal row; it simply reports existence.
- GET_REVENUE_RECOG_RUN_FLAG — Returns a flag describing the revenue recognition run status for a transaction and invoicing rule pairing.
- GET_CB_INVOICE — Returns chargeback invoice information for a given customer transaction and class.
- GET_DISPUTE_AMOUNT — Returns the disputed amount for a transaction, taking the class and open receivable flag into account.
- GET_DISPUTE_DATE / GET_MAX_DISPUTE_DATE — Return the dispute date and the latest dispute date respectively for a transaction, filtered by class and open receivable status.
- GET_POSTED_FLAG — Returns a flag describing whether a transaction is posted, considering the post-to-GL flag, completion flag, and optional class.
- GET_SELECTED_FOR_PAYMENT_FLAG — Indicates whether a transaction has been selected for payment.
- GET_ACTIVITY_FLAG — Returns an activity flag for a transaction based on open receivable, completion, class, and prior/initial transaction identifiers.
- GET_REFERENCE / GET_LINE_REFERENCE — Return reference string values for a transaction row or line row identified by ROWID.
- SET_REFERENCE_COLUMN — A procedure that sets the reference column name used by the reference functions.
- GET_FIRST_DUE_DATE / GET_FIRST_REAL_DUE_DATE — Return the first due date and the first real due date based on payment term, transaction date, and (for the real due date) the transaction identifier.
- GET_NUMBER_OF_DUE_DATES — Returns the count of due dates associated with a transaction or term.
- GET_PERIOD_NAME — Returns the accounting period name relevant to a transaction.
- GET_TERRITORY / GET_TERRITORY_ROWID — Return territory information and the corresponding ROWID.
- GET_COMMITMENTS_EXIST_FLAG / GET_AGREEMENTS_EXIST_FLAG — Return flags indicating whether commitments or agreements exist for the relevant entity.
Tables Accessed
The package reads from a range of Receivables and shared reference tables using APPS synonyms. Transaction and schedule data are sourced from RA_CUST_TRX_TYPES, AR_PAYMENT_SCHEDULES, and payment term definitions in RA_TERMS. Receipt and adjustment processing draw on AR_ADJUSTMENTS, AR_ADJUSTMENTS_ALL, AR_CASH_RECEIPT_HISTORY, AR_INTERIM_CASH_RECEIPTS, AR_INTERIM_CASH_RECEIPT_LINES, AR_RECEIPT_CLASSES, and AR_RECEIPT_METHODS. Dispute and correspondence data come from AR_DISPUTE_HISTORY, AR_CORRESPONDENCES, and AR_CORRESPONDENCE_PAY_SCHED. Customer contact and agreement data are sourced from HZ_CONTACT_POINTS and SO_AGREEMENTS.
Usage Notes
APPT_SQL_FUNC_UTIL is typically invoked from PL/SQL rather than directly from the user interface. Because many of its functions accept a customer_trx_id and return display-oriented values (flags, dates, amounts), it is commonly called by Receivables forms such as the Transactions and Collections workbench to populate derived fields without issuing separate queries. Concurrent programs in Revenue Recognition, invoicing, and collections also call these utilities. Custom code extending Receivables should treat these as read-only helper functions; they are primarily query-based and should not be relied upon to perform transactional updates. Given the package's AUTHID CURRENT_USER declaration, callers must hold appropriate privileges on the underlying APPS synonyms.