-
Is there any way to validate UTF-8 in regex?
I have basic validation rules setup for name fields:
NOT(REGEX(FirstName, "^[A-Za-z\\. '-]+$"))
Want to allow only letters, periods, spaces, hyphens and apostrophes in the name field. The problem with this is that it does not allow accented characters (graphemes). I've tried some simplified ideas based on a regex tutorial and the Java Docs Salesforce links to, but they do not work:
NOT( REGEX( FirstName , "\\P{M}\\p{M}") )
NOT( REGEX( FirstName , "\\p{Alpha}") )
NOT( REGEX( FirstName , "\\X") )
Has anybody else run into this problem? How do you validate names with accent marks?
Log In to reply.
Popular Salesforce Blogs
Salesforce Trigger Example to count number of completed tasks in a single contact
Below is an example of how to use Salesforce Trigger to count number of completed tasks in a single contact trigger UpdateAccountNameFromContactLastName2 on Contact (before…
Learn About Salesforce Einstein Prediction Builder
The Einstein Prediction Builder can help you predict which opportunities will close and which goods prospects will buy. Predictions may be created based on the…
A Machine Learning Approach to Deduping Salesforce
When we look at all of the Salesforce deduplication apps on the AppExchange, they all have one thing in common: they are all rule-based. Basically,…
Popular Salesforce Videos
Salesforce Winter 18 Release for Busy Admins
Contents: Lightning Report Builder Dashboard Report Filter Lightning Hover Components Conditional Page Components Setup Search in Lightning Lead Conversion Updates User Interface Settings
Top 10 Reasons to Learn Salesforce | Why Should you Learn Salesforce in 2021
The "Top 10 Reasons to Learn Salesforce" video will give you good reasons to learn and start your career in Salesforce. We will address the…
Salesforce Financial Services Cloud Spring '23 Highlights
Shake off those winter blues with the new features coming in Salesforce's Spring '23 Release for Financial Services Cloud. Whether it's ARC enhancements, interaction summary…