Search Results as_lead_lines_all




Overview

The AS_LEAD_LINES_ALL table is a core transactional entity within the Oracle E-Business Suite Sales Foundation module (AS). It functions as the detailed line-level repository for sales opportunities, which are managed as leads within the system. Each record in this table represents a specific product, service, or item of interest associated with a broader sales opportunity (lead). Its primary role is to enable the tracking of multiple potential revenue lines per opportunity, capturing granular details such as the product of interest, projected revenue, sales stage, and competitive information. This granular data is essential for accurate sales forecasting, pipeline analysis, and resource allocation.

Key Information Stored

The table's structure is defined by its primary and foreign keys, which enforce data integrity and establish critical relationships. The primary key is the LEAD_LINE_ID, a unique system-generated identifier for each opportunity line. A significant foreign key is LEAD_ID, which links each line to its parent opportunity header in the AS_LEADS_ALL table. Other vital foreign key relationships include INVENTORY_ITEM_ID and ORGANIZATION_ID (linking to the product catalog in MTL_SYSTEM_ITEMS_B), SALES_STAGE_ID (linking to AS_SALES_STAGES_ALL_B), and interest type and code identifiers (INTEREST_TYPE_ID, PRIMARY_INTEREST_CODE_ID). These columns collectively store the core transactional data for an opportunity line item.

Common Use Cases and Queries

This table is central to sales operations reporting and data extraction. Common use cases include generating a detailed opportunity pipeline report, calculating weighted revenue forecasts by line item, and analyzing product performance within the sales cycle. A typical query would join AS_LEAD_LINES_ALL to its parent and related tables to retrieve a comprehensive view. For example, to list all active opportunity lines with their product and stage information, a query might be structured as follows:

  • SELECT all.lead_line_id, all.lead_id, h.lead_number, msib.segment1 item_code, all.forecast_amount, stg.name sales_stage
  • FROM as_lead_lines_all all,
  • as_leads_all h,
  • mtl_system_items_b msib,
  • as_sales_stages_all_b stg
  • WHERE all.lead_id = h.lead_id
  • AND all.inventory_item_id = msib.inventory_item_id
  • AND all.organization_id = msib.organization_id
  • AND all.sales_stage_id = stg.sales_stage_id
  • AND h.status_code = 'OPEN';

Related Objects

AS_LEAD_LINES_ALL is a hub for numerous related entities, as indicated by its extensive foreign key relationships. Key parent tables include AS_LEADS_ALL (header), MTL_SYSTEM_ITEMS_B (product), and AS_SALES_STAGES_ALL_B (stage). Crucially, it serves as a parent to several child tables that store additional line-specific attributes, such as AS_LEAD_COMP_PRODUCTS (competing products), AS_LEAD_DECISION_FACTORS, AS_SALES_CREDITS (sales team compensation), and AS_OPP_COMPETING_PRODS. It is also referenced by ASO_QUOTE_RELATED_OBJECTS, linking opportunity lines to formal quotes. This network of relationships underscores the table's integral position in the sales transaction architecture.