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
Tarun KaushikTarun Kaushik 

How to combine two IF condition in 'OR' in one validation Rule

Hi 
I have two validation rule for Two custom fields on Accounts with different error message 
1-IF(OR(ISBLANK(custom_field_1),ISBLANK(PRIORVALUE(custom_field_1))),false 
,ISCHANGED(custom_field_1))

2-IF(OR(ISBLANK(custom_field_2),ISBLANK(PRIORVALUE(custom_field_2))),false 
,ISCHANGED(custom_field_2))

Now I want to combine this two validation rule as 'OR' condition  in one validation Rule with common error message 
John Pipkin 14John Pipkin 14
Tarun, 

You can wrap both IF statements in an OR function
OR(
IF(OR(ISBLANK(custom_field_1),ISBLANK(PRIORVALUE(custom_field_1))),false 
,ISCHANGED(custom_field_1)),
IF(OR(ISBLANK(custom_field_2),ISBLANK(PRIORVALUE(custom_field_2))),false 
,ISCHANGED(custom_field_2))
)

Hope that helps