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
Venu MVenu M 

Record Type - Validation Rule

Hi, I need to create a validation rule for record type to restrict the user from creating with 2 conditions, one when the email is blank and another when (screening pick value is unscreened and Territory Lookup is blank), following is something I tried but it works for first condition but not the second. 

AND( 
$RecordType.Name = "Partner", 
ISBLANK(Email),
OR($RecordType.Name = "Partner", 
ISPICKVAL(Screening__c, "Unscreened"),
ISBLANK(Sales_Territory__c))))
Dushyant SonwarDushyant Sonwar
Venu,

Try this,

This should work fine.
AND( 
$RecordType.Name = "Partner", 

OR(ISBLANK(Email) , ISNULL(Email) )
,
OR($RecordType.Name = "Partner", 
ISPICKVAL(Screening__c, "Unscreened"),
OR(ISBLANK(Sales_Territory__c) , ISNULL(Sales_Territory__c) )) )

Another Idea i would love to give is that you can remove the first condition of email in your validation rule and make the email field mandatory on page layout level for Partner recordType.



Hope this helps!