function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
Tom FalconerTom Falconer 

My current validation rule allows a sales team member to convert a lead at 25% or greater

My current validation rule allows a sales team member to convert a lead at 25% or greater. I want to allow them to convert a lead if its 14% or high if a project tag = High Priority.



Current validation rule is:



AND( 

ISCHANGED(Lead_Sub_Status__c), 

OR( 

ISPICKVAL(Lead_Sub_Status__c ,"Ready for Onboarding, menu received"), 

ISPICKVAL(Lead_Sub_Status__c ,"Resell Successful, ready for Onboarding")), 

NOT(Or($UserRole.Name = "Team Lead",$UserRole.Name = "Data Team")), 

ISPICKVAL(Status,"DocuSign Complete"), 

Profit_Share__c < 0.25 

)



How can I update this rule to allow for that exception?



Thanks for your help
Saravana Muthu 8Saravana Muthu 8
Hi,

Please try like below and let me know if it works.

AND( 

ISCHANGED(Lead_Sub_Status__c), 

OR( 

ISPICKVAL(Lead_Sub_Status__c ,"Ready for Onboarding, menu received"), 

ISPICKVAL(Lead_Sub_Status__c ,"Resell Successful, ready for Onboarding")), 

NOT(Or($UserRole.Name = "Team Lead",$UserRole.Name = "Data Team")), 

ISPICKVAL(Status,"DocuSign Complete"), 

Profit_Share__c < 0.14, NOT(ISPICKVAL(Project_tag__c,"High Priority"))
)

Thanks,
Sarav
Sweet Potato Tec
 
Tom FalconerTom Falconer
This did not work. I was able to convert a lead at 14% regardless if the project tag was High Priority or not
Saravana Muthu 8Saravana Muthu 8
Try this one please.

AND( 

ISCHANGED(Lead_Sub_Status__c), 

OR( 

ISPICKVAL(Lead_Sub_Status__c ,"Ready for Onboarding, menu received"), 

ISPICKVAL(Lead_Sub_Status__c ,"Resell Successful, ready for Onboarding")), 

NOT(Or($UserRole.Name = "Team Lead",$UserRole.Name = "Data Team")), 

ISPICKVAL(Status,"DocuSign Complete"), 

Profit_Share__c <=  0.14, NOT(ISPICKVAL(Project_tag__c,"High Priority"))
)

Thanks,
Sarav
Sweet Potato Tec
Tom FalconerTom Falconer
Didn't work
Tom FalconerTom Falconer
To clarify for everyone...

I want the minimum to be 25%, unless project tag = High Priority. Then they are allowed to convert at a lower %
Saravana Muthu 8Saravana Muthu 8
Hi,

Sorry, Let me clear myslef this time.Your sales team member should convert a lead if it's 14% or higher and if Project Tag="High Priority". Is that correct?

If it's less that 14% and Project tag not equals to High Priority is should display error.

Thanks,
Sarav
Sweet Potato Tec
Tom FalconerTom Falconer
Savanaga: Normally, if the % is lower than 25, an error should display. I want to allow an exception so that if project tag = high priority, then they are able to convert a lead down to 14%. Anything lower than that in that situation should display an error
Tom FalconerTom Falconer
Savana: I don't see a rule in there to not allow a sales member to convert the lead if it's under 25%. It just looks like you've considered the 14% and Project tag
Saravana Muthu 8Saravana Muthu 8
Hi,

Sorry, Yes I thought the % should allow only 14%.

AND( 

ISCHANGED(Lead_Sub_Status__c), Profit_Share__c <  0.14, ISPICKVAL(Project_tag__c,"High Priority")

OR( 

ISPICKVAL(Lead_Sub_Status__c ,"Ready for Onboarding, menu received"), 

ISPICKVAL(Lead_Sub_Status__c ,"Resell Successful, ready for Onboarding")), 

NOT(Or($UserRole.Name = "Team Lead",$UserRole.Name = "Data Team")), 

ISPICKVAL(Status,"DocuSign Complete"), 

(Profit_Share__c >  0.14 && Profit_Share__c <  0.25)
)

Thanks,
Sarav
Sweet Potato Tec
Tom FalconerTom Falconer
Savana: What about leads that don't have project tag = High Priority? To me it looks like you're trying to build the project tag into the formula, instead of having it as an exception to the rule.  The rule should be profit share < 25% and I need to build into it an exception that allows profit share < 14 if project tag = high priority. If project tag does not equal high priority, then profit share should be < 25
Saravana Muthu 8Saravana Muthu 8
So just to be clear if your project tag equals high priority then profit share greater than 14% and team member can convert.

if project tag is not equals high priority it should be greater than 25% and team memebr can convert.

Correct ?
Tom FalconerTom Falconer
Correct
Saravana Muthu 8Saravana Muthu 8
Hi,

Try below and let me know.
AND( 

ISCHANGED(Lead_Sub_Status__c), 

OR( 

ISPICKVAL(Lead_Sub_Status__c ,"Ready for Onboarding, menu received"), 

ISPICKVAL(Lead_Sub_Status__c ,"Resell Successful, ready for Onboarding")), 

NOT(Or($UserRole.Name = "Team Lead",$UserRole.Name = "Data Team")), 

ISPICKVAL(Status,"DocuSign Complete"), 

(Profit_Share__c < 0.25 && NOT(ISPICKVAL(Project_tag__c="High Priority)),

Profit_Share__c < 0.14 && ISPICKVAL(Project_tag__c="High Priority)

)

Thanks,
Sarav
Sweet Potato Tec
Saravana Muthu 8Saravana Muthu 8
Sorry is pickval should be like below.

AND( 

ISCHANGED(Lead_Sub_Status__c), 

OR( 

ISPICKVAL(Lead_Sub_Status__c ,"Ready for Onboarding, menu received"), 

ISPICKVAL(Lead_Sub_Status__c ,"Resell Successful, ready for Onboarding")), 

NOT(Or($UserRole.Name = "Team Lead",$UserRole.Name = "Data Team")), 

ISPICKVAL(Status,"DocuSign Complete"), 

(Profit_Share__c < 0.25 && NOT(ISPICKVAL(Project_tag__c,"High Priority)),

Profit_Share__c < 0.14 && ISPICKVAL(Project_tag__c,"High Priority)

)
Saravana Muthu 8Saravana Muthu 8
Hi,

Can you please let me know if this is worked ?