Salesforce Asked on December 14, 2021
Could you please help me out on this requirement.
getting an error: The formula expression is invalid: Syntax error. Missing ‘)’
I have a process builder where it should change the owner when the status field value is changed from Rejected to New and the Country should be any of list and should consider if there are any zip codes that starts with some numbers. I tried a formula but getting the error.
AND
(ISPICKVAL(PRIORVALUE([Lead].Status), "Rejected") ,
ISPICKVAL([Lead].Status, "New"),
ISCHANGED([Lead].Status),
AND(OR
(
ISPICKVAL([Lead].State , "North Carolina"),
ISPICKVAL([Lead].State, "South Carolina"),
ISPICKVAL([Lead].State, "Georgia"),
ISPICKVAL([Lead].State, "Florida"),
ISPICKVAL([Lead].State, "Alabama"),
ISPICKVAL([Lead].State, "Tennessee"),
))
AND(OR(BEGINS([Lead].PostalCode , 50) ,
BEGINS([Lead].PostalCode , 56)
)
)
)
You're missing a comma, for starters. Secondly, the latter two ANDs are superfluous. Also, the last two "numbers" are still strings, and need to be in quotes.
AND(
ISPICKVAL(PRIORVALUE([Lead].Status), "Rejected"),
ISPICKVAL([Lead].Status, "New"),
ISCHANGED([Lead].Status),
OR(
ISPICKVAL([Lead].State , "North Carolina"),
ISPICKVAL([Lead].State, "South Carolina"),
ISPICKVAL([Lead].State, "Georgia"),
ISPICKVAL([Lead].State, "Florida"),
ISPICKVAL([Lead].State, "Alabama"),
ISPICKVAL([Lead].State, "Tennessee"),
),
OR(
BEGINS([Lead].PostalCode , "50"),
BEGINS([Lead].PostalCode , "56")
)
)
Answered by sfdcfox on December 14, 2021
Get help from others!
Recent Questions
Recent Answers
© 2024 TransWikia.com. All rights reserved. Sites we Love: PCI Database, UKBizDB, Menu Kuliner, Sharing RPP