0

I have an object called Endorsement and a multi select picklist on it called Endorsement Type which has two values "Add Cover" and "Remove Cover".I have separate validations for both.For Add Cover it is required to save the Premium with a positive value and for Remove Cover the premium should be negative.I need a third criteria that when both the values add and remove cover are selected I can save the premium with any value positive or negative.

Validations:

a) Remove Cover
AND ( 
INCLUDES( Endorsement_Type__c , "Remove Cover") , 
Active__c = TRUE, 
OR ( ISNULL(Premium__c ) , 
Premium__c >= 0))

b) 
AND ( 
INCLUDES( Endorsement_Type__c , "Add Cover") , 
 Active__c = TRUE,
 Premium__c <=0 || ISNULL (Premium__c )
)
1

can you try below, use bold line as below

OR( AND ( INCLUDES( Endorsement_Type__c , "Remove Cover") , NOT(INCLUDES( Endorsement_Type__c , "Add Cover")) Active__c = TRUE, OR ( ISNULL(Premium__c ) , Premium__c >= 0))

AND ( INCLUDES( Endorsement_Type__c , "Add Cover") , NOT(INCLUDES( Endorsement_Type__c , "Remove Cover")) Active__c = TRUE, Premium__c <=0 || ISNULL (Premium__c ) )

)

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.