I’m new to bpm’s. I have created a custom field in Customer to possibly hold multiple AP email addresses separated by semicolons.
I am working on the BPM customer Update and want to check the syntax of the email address. My condition uses “The specified field of the changed row matches the specified condition.” I used @"^[a-zA-Z-9._%+-]+@[a-zA-Z-9.-]+\.[a-zA-Z]{2,}$"
as the specified condition. This works well for 1 email, but it fails as soon as I add a second one. Does anyone know how to change that format, or is there a simpler way?
Chat GPT does a pretty good job of helping out with regex formulas. This is what it gave me back.
^([a-zA-Z0-9._%+-]+@[a-zA-Z0-9.-]+\.[a-zA-Z]{2,})(;\s*[a-zA-Z0-9._%+-]+@[a-zA-Z0-9.-]+\.[a-zA-Z]{2,}){0,9}$
5 Likes
It’s the number 1 feature!
1 Like
All my years at uni bashing my head against a wall trying to understand regex syntax are for nought!
3 Likes
I think if you replace {0,9}
with *
, then you’ll have none or many, instead of being limited to 9 additional emails after the first one…
Edit: confirmed this on regexpal dot com…
1 Like