Search Results lead_contact_role




Overview

APPS.AS_SALES_LEAD_CONTACTS_V is a reporting and integration view in Oracle E-Business Suite that exposes sales lead contact assignments along with the denormalized party, phone, and relationship attributes associated with each contact. It is defined in the Sales Foundation (AS) module and draws its driving rows from AS_SALES_LEAD_CONTACTS, joined across the Oracle Trading Community Architecture (TCA) tables HZ_PARTIES, HZ_RELATIONSHIPS, and HZ_CONTACT_POINTS, together with the AR_LOOKUPS and AS_LOOKUPS lookup views. The view presents a flattened record for every contact linked to a sales lead, avoiding the multi-table joins that would otherwise be required to resolve lead-to-contact relationships.

Its principal significance for consultants and developers is the exposure of the CONTACT_ROLE_CODE column, which stores the role played by the contact on the lead — the attribute most frequently searched as lead_contact_role. Because the view combines lead contact data with TCA party details such as first name, last name, title, and e-mail address, it is a convenient single source for lead contact reporting, list generation, and outbound integrations. The view is available in both 12.1.1 and 12.2.2; the underlying table structures are consistent across those releases.

Underlying Base Objects

The ETRM metadata documents the following referenced objects:

The joins are driven from AS_SALES_LEAD_CONTACTS through CONTACT_PARTY_ID to HZ_RELATIONSHIPS.PARTY_ID, then to HZ_PARTIES on SUBJECT_ID, forming the contact-relationship chain that links a lead contact to the correct TCA party record.

Key Columns

  • LEAD_CONTACT_ID — primary identifier of the lead contact row.
  • SALES_LEAD_ID — the sales lead to which the contact is assigned; the key for lead-level reporting.
  • CONTACT_ID / CONTACT_PARTY_ID — the TCA party identifiers for the contact.
  • CONTACT_ROLE_CODE — the role of the contact on the lead (the lead_contact_role attribute); codes are typically validated against lookup types surfaced through AS_LOOKUPS.
  • FIRST_NAME, LAST_NAME, PERSON_TITLE — denormalized contact identity fields from HZ_PARTIES.
  • EMAIL_ADDRESS — the contact's e-mail from the related party record.
  • PHONE_COUNTRY_CODE, AREA_CODE, PHONE_NUMBER, EXTENSION, PHONE_TYPE — contact phone details with the decoded phone type meaning.
  • PRIMARY_CONTACT_FLAG / PRIMARY_FLAG — indicate the primary contact for the lead and the primary phone.
  • RANK, ENABLED_FLAG, CUSTOMER_ID, ADDRESS_ID, PHONE_ID — ordering, status, and contextual references.
  • RELATIONSHIP_CODE, RELATIONSHIP_ID, SUBJECT_PARTY_ID, OBJECT_PARTY_ID — relationship context between parties.
  • ROW_ID / CONTACT_ROW_ID — physical row identifiers useful for DML or de-duplication.

Common Use Cases and Queries

Typical scenarios include lead contact role reporting, contact list extraction for campaigns, and integration feeds requiring denormalized contact details. A search for the lead contact role is commonly expressed as:

  • List all contacts and their roles for a given sales lead, ordered by rank.
  • Identify primary contacts for leads, including e-mail and phone.
  • Report lead contacts filtered by CONTACT_ROLE_CODE.

Sample query:

SELECT v.sales_lead_id, v.lead_contact_id, v.contact_role_code, v.first_name, v.last_name, v.email_address, v.phone_number, v.primary_contact_flag FROM apps.as_sales_lead_contacts_v v WHERE v.sales_lead_id = :p_lead_id AND v.enabled_flag = 'Y' ORDER BY v.rank;

To filter specifically on the role: SELECT v.sales_lead_id, v.first_name, v.last_name, v.contact_role_code FROM apps.as_sales_lead_contacts_v v WHERE v.contact_role_code = :p_role AND v.enabled_flag = 'Y'; Because the view decodes phone types through AR_LOOKUPS and applies multiple TCA joins, queries should filter on indexed keys such as SALES_LEAD_ID or LEAD_CONTACT_ID to maintain acceptable performance in high-volume reporting environments.