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
Praveen BonaluPraveen Bonalu 

Compare the Phone numbers and display the errors when they match

Hi experts,

I have 5 phone fileds 

1)home phone
3)work phone
5)reference 2 phone.

None of the filelds should have the same number .Is it possible to display the error through the validation rule if the fileds have same number 

ajay rawat 14ajay rawat 14
Hi Praveen
         You have to create a new validation rule and add logical condition in OR operator like
OR( Home_phone__c == cellphone__c,Home_phone__c == work_phone__c,..... )

Thanks and Regards,
Ajay Rawat
You can use the below validation rule to compare the value between multiple (replace the name of the field with the API name)
IF( homephone  =   cellphone || homephone = workPhone || homephone = reference1phone || homePhone =reference2phone  , True, 
   If(cellphone = workPhone || cellPhone = reference1phone || cellphone = reference2phone,True,
      If(workPhone = reference1phone || workPhone = reference2phone,True,
         If(reference1phone = reference2phone,true,false  ))))
Hi Praveen',
Just copy and paste the rule and let me know this is fine for your problem and i did test in my org also.

OR( Home_phone__c == cellphone__c,Home_phone__c == work_phone__c,Home_phone__c == reference1phone__c,Home_phone__c==reference2phone__c )

Gyanender Singh