Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

How to make sure my Phone Number field has 10 digits??

JayJuan Jones
Contributor
January 12, 2023

Can someone give me some ideas on how to validate my custom field "Phone Number"? This is a text field, and it accepts integer values, but we are running into issues where some of our external help desk members are not capturing all 10 digits of the phone number. Previously I tried to make the field required but it ended up breaking the template of the issues we receive via email (only Description and Summary can be required). Any way I can validate the field upon issue create using regex? Any other suggestions? 

1 answer

1 vote
Walter Buggenhout
Community Champion
January 12, 2023

Hi @JayJuan Jones,

A regex validator on the create transition of your workflow is basically the out-of-the-box way you could set this up.

This KB article has a good description of your use case. It even refers to a phone number custom field as an example on how to set it up.

Hope this helps! 

JayJuan Jones
Contributor
January 13, 2023

hello, I tried to use the regular expression below and that didn't work for me :(

^[0-9]{n}$

Suggest an answer

Log in or Sign up to answer