Frequently used Regular Expressions
Use Regular Expressions on a Text Line to validate the data. For example:
Input Mask forces the data to be input into the field in the matching conditions set.
Validation Regex delivers an error on the field if the data doesn't match the conditions set.
Condition |
Explanation |
Regex |
|
This regex matches any string that consists of a username, followed by an @ symbol, followed by a domain name, followed by a dot, followed by a top-level domain. The username can contain letters, numbers, periods, underscores, or hyphens. The domain name can contain letters, numbers, periods, or hyphens. The top-level domain can contain two or more letters. |
|
Phone |
This regex is used to match a specfic pattern of text, representing phone numbers in the format "###-###-####". |
|
Credit Card |
This regex matches any string that consists of 16 digits. The digits can be any number from 0 to 9. |
|
Credit Card Expiry |
This regex is designed to match a specific pattern of text, that represent dates in the format "MM/DD" where MM is the month (01 to 12) and DD is the day (22 to 39). |
|
Currency Code |
This regex matches any string that consists of three uppercase letters. |
|
US ZIP Code |
This regex matches any string that consists of five digits. |
|
IP Address |
This regex matches any string that consists of four numbers, separated by periods. Each number can be from 0 to 255. |
|
Passwords |
This regex is designed to enforce certain password complexity requirements. It checks if a string contains at least one special character from the set [!@#$%^&*()_+[\]{};':"\\|,.<>/?] and is at least 8 characters long. |
|