Search Results pa_draft_invoice_items




Overview

The PA_DRAFT_INVOICE_ITEMS table is a core transactional table within the Oracle E-Business Suite Projects (PA) module, specifically for releases 12.1.1 and 12.2.2. It functions as the detailed line-level repository for draft invoices. A draft invoice is a preliminary, unapproved version of a customer invoice generated from project-related revenue and costs. This table stores each individual line item that constitutes a draft invoice, capturing detailed financial, descriptive, and transactional data before the invoice is finalized and transferred to Oracle Receivables. Its role is critical in the project-to-cash cycle, enabling review, adjustment, and approval of invoice details prior to official billing.

Key Information Stored

The table's structure, as indicated by its primary and foreign keys, stores comprehensive line item details. The primary key is a composite of PROJECT_ID, DRAFT_INVOICE_NUM, and LINE_NUM, ensuring uniqueness for each line within a draft invoice for a specific project. Key columns and their purposes include financial attributes like REVENUE_AMOUNT, HARD_LIMIT, and CC_REV_CODE_COMBINATION_ID (linking to the revenue account in GL). Descriptive data is held in ITEM_DESCRIPTION and references to project work breakdown structures via TASK_ID. The table also manages tax information through OUTPUT_VAT_TAX_ID, customer site details via SHIP_TO_ADDRESS_ID, and supports complex billing scenarios with columns for retention (RETN_DRAFT_INVOICE_NUM, RETN_DRAFT_INVOICE_LINE_NUM, RETN_BILLING_CYCLE_ID). Multiple foreign key relationships to FND_LOOKUP_VALUES (FLE_LOOKUP_TYPE/CODE) indicate the storage of standardized classification data for line items.

Common Use Cases and Queries

Primary use cases revolve around draft invoice inquiry, adjustment, and audit reporting. Common operational queries include reviewing all lines for a specific draft invoice, analyzing lines by task or revenue account, and identifying lines with retention applied. For reporting, analysts often join this table to PA_DRAFT_INVOICES_ALL, PA_PROJECTS_ALL, and PA_TASKS to create detailed draft invoice registers. A typical query pattern is:

  • SELECT pdi.project_id, pdi.draft_invoice_num, pdii.line_num, pdii.item_description, pdii.revenue_amount, pt.task_number
  • FROM pa_draft_invoice_items pdii,
  • pa_draft_invoices_all pdi,
  • pa_tasks pt
  • WHERE pdii.project_id = pdi.project_id
  • AND pdii.draft_invoice_num = pdi.draft_invoice_num
  • AND pdii.task_id = pt.task_id
  • AND pdi.project_id = :p_project_id;

Technical consultants may query this table to troubleshoot invoice generation or validate data integrity before final approval and transfer to Receivables.

Related Objects

PA_DRAFT_INVOICE_ITEMS has extensive relationships within the EBS schema, primarily with other Projects and financial tables. Its most direct parent is PA_DRAFT_INVOICES_ALL, which stores the draft invoice header. It references master data tables including PA_PROJECTS_ALL, PA_TASKS, and PA_BILLING_CYCLES. For financial integration, it links to GL_CODE_COMBINATIONS for accounting flexfields and to AR_VAT_TAX_ALL_B for tax codes. Customer data is referenced via HZ_CUST_ACCT_SITES_ALL or RA_ADDRESSES_ALL for ship-to addresses. The table also supports a recursive relationship to itself to handle retention lines. Key APIs for creating and manipulating data in this table are typically part of the Oracle Projects Invoice package (PA_INVOICE_UTILS, PA_DRAFT_INVOICE_PUB).