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
Ellie AfatmirniEllie Afatmirni 

Hi guys, need help with a pick list validation rule

I want to throw an error when a picklist value that contains "PP" is changed to a picklist value that does not contain "PP". Thanks in adavnce :)
SwethaSwetha (Salesforce Developers) 
HI Ellie,
 
Is "PP" part of the word in the picklist?  Like A"pp"le changed to Orange(does not contain PP)?
Ellie AfatmirniEllie Afatmirni
Yes exactly
Reddy RakeshReddy Rakesh
Hi Afatmirni,

Try this code.. replace Location__c with your picklist filed name
AND(
CONTAINS(TEXT(PRIORVALUE(Location__c )),"PP"), NOT( CONTAINS( TEXT( Location__c ), "PP") ))