Search Results projacct_bill_amount




Overview

The PA_DRAFT_INVOICE_DETAILS view is a reporting and inquiry layer within the Oracle Projects (PA) module that exposes draft invoice line details generated during the project billing cycle. In Oracle EBS 12.1.1 and 12.2.2, this view consolidates the detail rows produced when the Invoice Generation program processes billable expenditures, events, and markup against a project or contract. Each row represents a single draft invoice detail, tying an expenditure item or billing source to a specific draft invoice number and line number.

The view is defined over PA_DRAFT_INVOICE_DETAILS_ALL, an Oracle Projects multi-organization (MOAC) base table, and applies the standard CLIENT_INFO-based operating unit filter. This means the view returns only rows for the operating unit set in the session's client information, providing organization-level security for reporting. The view is commonly used by billing analysts, project accountants, and integration developers who need to inspect, reconcile, or extract draft invoice content prior to invoice creation and accounting.

Underlying Base Objects

Per the documented metadata, the view is built on the PA_DRAFT_INVOICE_DETAILS_ALL table. The view text shows a direct projection of the table's columns with a WHERE clause restricting ORG_ID to the session operating unit. The predicate uses NVL and DECODE against USERENV('CLIENT_INFO') to derive the current organization, comparing it to ORG_ID and falling back to -99 when no context is set. No other base objects are documented as referenced, so the view is effectively a secured, denormalized projection of the underlying billing detail table.

The columns exposed span both transactional billing data (amounts, currency, rates, tax attributes, transfer pricing) and standard EBS audit columns (WHO columns such as CREATION_DATE, CREATED_BY, LAST_UPDATE_DATE, and the PROGRAM/REQUEST identifiers). Because no joins are documented, the view does not by itself resolve project names, task names, or customer names; those require joins to PA_PROJECTS_ALL, PA_TASKS, and related billing tables.

Key Columns

The following columns are of particular importance for reconciliation and reporting:

Common Use Cases and Queries

Typical uses include reconciling draft invoice amounts back to expenditures, diagnosing why a specific line was generated with a given rate or markup rule, and extracting draft invoice detail for external reporting before the invoice is finalized. The IND_COMPILED_SET_ID column is frequently used to trace which compiled billing rule set drove a line's calculation.

Example query returning draft invoice details for the current operating unit and a specific draft invoice:

  • SELECT d.draft_invoice_num, d.draft_invoice_line_num, d.line_num, d.expenditure_item_id, d.bill_amount, d.denom_currency_code, d.ind_compiled_set_id, d.bill_rate, d.bill_markup_percentage FROM pa_draft_invoice_details d WHERE d.draft_invoice_num = :invoice_num ORDER BY d.draft_invoice_line_num, d.line_num;

Example query grouping bill amounts by compiled rule set to analyze rule application:

  • SELECT d.ind_compiled_set_id, COUNT(*) detail_count, SUM(d.bill_amount) total_bill FROM pa_draft_invoice_details d WHERE d.request_id = :request_id GROUP BY d.ind_compiled_set_id ORDER BY total_bill DESC;

Because the view enforces the operating unit predicate automatically, queries executed in the correct MOAC context return only the relevant organization's rows, which simplifies secure reporting and integration extracts.