Sample Scoring Calculations Formulas

Score leads by source or rating, and rank customers based on survey results.

Required Editions

Available in: both Salesforce Classic and Lightning Experience
Available in: Essentials, Group, Professional, Enterprise, Performance, Unlimited, and Developer Editions

For details about using the functions included in these samples, see Formula Operators and Functions by Context.

Lead Scoring

This formula scores leads, providing a higher score for phone calls than website requests.

CASE(LeadSource, "Phone", 2, "Web", 1, 0)

Here's a formula that scores a lead based on his or her rating:

CASE(1, IF(ISPICKVAL​(Rating, "Hot"),​ 1, 0), 3,​​ IF(ISPICKVAL​(Rating, "Warm"),​ 1, 0), 2, IF(ISPICKVAL​(Rating, "Cold"),​ 1, 0), 1))

Customer Success Scoring

This formula uses a simple scoring algorithm to rank customers a high score for positive survey results in Salesforce.

Survey_Question_1__c * 5 + Survey_Question_2__c *2