Search Results ams_p_source_codes_v




Overview

AS_SALES_LEAD_LINES_V is a reporting view owned by the APPS schema in Oracle E-Business Suite, delivered as part of the AS – Sales Foundation product family. It is built on top of the AS_SALES_LEAD_LINES base entity and exposes sales lead line records enriched with descriptive foreign key information. The view's documented purpose is to resolve sales lead line foreign keys, meaning it denormalizes the underlying normalized lead-line table so that identifiers such as interest type, primary and secondary interest codes, inventory items, units of measure, campaigns, and offers are surfaced as human-readable names and codes rather than raw numeric IDs.

Because a search for primary_interest_code maps directly to this object, the view is the canonical source for anyone wishing to display or filter sales lead lines by the interest classification applied to a lead. In EBS 12.1.1 and 12.2.2 the view remains valid and is used primarily for reporting, inquiry screens, and integration extracts where descriptive lead-line attributes are required without joining multiple lookup tables.

Underlying Base Objects

The view is defined over the following documented base objects:

Key Columns

  • SALES_LEAD_LINE_ID, SALES_LEAD_ID, ROW_ID – primary identifier, parent lead reference, and row locator.
  • STATUS_CODE – the lead line status.
  • INTEREST_TYPE_ID / INTEREST_TYPE – the interest type foreign key and its translated name.
  • PRIMARY_INTEREST_CODE_ID / PRIMARY_INTEREST_CODE – the primary interest classification most relevant to the primary_interest_code search term.
  • SECONDARY_INTEREST_CODE_ID / SECONDARY_INTEREST_CODE – the secondary interest classification.
  • INVENTORY_ITEM_ID, ORGANIZATION_ID, CONCATENATED_SEGMENTS, ITEM_DESCRIPTION – item context for the lead line.
  • UOM_CODE, UNIT_OF_MEASURE_TL, QUANTITY, BUDGET_AMOUNT – commercial quantities and value.
  • OFFER_ID, OFFER_NAME, OFFER_CODE, SOURCE_PROMOTION_ID, CAMPAIGN_NAME, CAMPAIGN_ID, CAMPAIGN_CODE, SOURCE_CODE – campaign and offer attribution.
  • ATTRIBUTE_CATEGORY and ATTRIBUTE1–ATTRIBUTE15 – descriptive flexfield values.

Common Use Cases and Queries

Typical scenarios include lead pipeline reporting by interest classification, campaign response analysis, and integration extracts feeding CRM or data warehouses. The following query lists lead lines filtered by primary interest code:

  • SELECT sales_lead_line_id, sales_lead_id, status_code, primary_interest_code, secondary_interest_code, item_description, quantity, budget_amount FROM apps.as_sales_lead_lines_v WHERE primary_interest_code = :p_code;
  • SELECT primary_interest_code, COUNT(*) FROM apps.as_sales_lead_lines_v GROUP BY primary_interest_code;
  • SELECT campaign_name, offer_name, primary_interest_code, SUM(budget_amount) FROM apps.as_sales_lead_lines_v GROUP BY campaign_name, offer_name, primary_interest_code;

Because the view already resolves the foreign keys, no additional joins to the interest code or item tables are required, which simplifies report SQL and reduces the risk of duplicate rows in multi-language deployments.