RT_LEAD_RATE_VW

(SQL View)
Index Back

Lead Rating Comparison View

View to compare Lead Ratings as assigned by Telemarketing to Lead Ratings as accepted or changed by Sales.

SELECT A.LEAD_ID , A.RA_CAMPAIGN_ID , A.RA_CMPGN_WAVE_ID , A.BUSINESS_UNIT , A.TREE_NAME , A.TERRITORY_ID , A.ACCEPTED_DT , A.REJECTED_DT , A.CONV_FROM_TLM_DTTM , A.LEAD_RATING , A.PERSON_ID , A.SALES_USER_NAME , B.SETID_PROV_GRP , B.PROVIDER_GRP_ID , B.ASSIGNED_TO , B.LEAD_RATING FROM PS_RSF_LEAD A , PS_RC_CALL_RESULT B WHERE A.RC_PROSPECT_SW = 'N' AND A.CONV_FROM_TLM_DTTM IS NOT NULL AND A.LEAD_ID = B.LEAD_ID AND B.RC_FINAL_DISPOSTN <> ' ' AND B.SEQNO = ( SELECT MAX( C.SEQNO) FROM PS_RC_CALL_RESULT C WHERE C.LEAD_ID = B.LEAD_ID)

# PeopleSoft Field Name PeopleSoft Field Type Database Column Type Description
1 LEAD_ID Character(15) VARCHAR2(15) NOT NULL Used by Sales Force Automation, this field uniquely identifies a Sales Lead.
2 RA_CAMPAIGN_ID Character(15) VARCHAR2(15) NOT NULL Marketing - Campaign Identification field. Character field that will contain a generated campaign or free form entered campaign id.
3 RA_CMPGN_WAVE_ID Character(15) VARCHAR2(15) NOT NULL Used to uniquely identify a Marketing - Campaign Activity (wave) ID
4 BUSINESS_UNIT Character(5) VARCHAR2(5) NOT NULL Business Unit
5 TREE_NAME Character(18) VARCHAR2(18) NOT NULL Tree Name
6 TERRITORY_ID Character(20) VARCHAR2(20) NOT NULL Territory ID
7 ACCEPTED_DT Date(10) DATE Accepted Date
8 REJECTED_DT Date(10) DATE Rejected Date
9 CONV_FROM_TLM_DTTM DateTime(26) TIMESTAMP Convert from TeleSales Date and Time
10 LEAD_RATING Character(2) VARCHAR2(2) NOT NULL Used by Sales Force Automation to indicate the value (rating) of a lead, i.e. whether it's a Hot Lead or a Cold Lead.
11 PERSON_ID Character(15) VARCHAR2(15) NOT NULL Person ID
12 SALES_USER_NAME Character(50) VARCHAR2(50) NOT NULL Sales User Name field
13 SETID_PROV_GRP Character(5) VARCHAR2(5) NOT NULL SetID
14 PROVIDER_GRP_ID Character(10) VARCHAR2(10) NOT NULL Identification number for the provider group.
15 ASSIGNED_TO Character(15) VARCHAR2(15) NOT NULL This is a field to store assignment information.
16 RT_LEAD_RATING Character(2) VARCHAR2(2) NOT NULL Used by Telemarketing to indicate the value (rating) of a lead, i.e. whether it's a Hot Lead or a Cold Lead. Used to compare to final Sales Lead Rating.