Validation Rule to support 10 digit number or Email Address Salesforce

Validation Rule to support 10 digit number or Email Address Salesforce

Check the following formula for Validation Rule to support 10 digit number or Email Address.

Validation Rule:

NOT ( 
OR ( REGEX( InfallibleTech__Employee_Name__c , '[0-9]{10}'), 
REGEX ( InfallibleTech__Employee_Name__c , '[a-zA-Z0-9._-]+@[a-zA-Z]+.[a-zA-Z]{2,4}') 
) )

Note:

Kindly replace your field name.

Leave a Reply