Number only variable in service catalog

ServiceNow Use6
Tera Guru

Hi,

I have a requirement to enter a number ONLY in the value section of a variable. Which variable type of the service catalog will allow it?

Regards

Suman P.

4 REPLIES 4

MrMuhammad
Giga Sage

Hi,

No OOB type available but you can use sing line text with Regex validator to only allow numbers.

There is OOB Regex available so you just need to configure variable.

You just need to add Number in Validation Regex field on the variable under Type Specification section.

find_real_file.png

 

Regards,

Muhammad

Regards,
Muhammad

Thank you so much For regex I will select a number but the variable type would be?

Regards

Suman P.

Variable type - Single line text

Regards,
Muhammad

variable type - Single line text.

List of available regex can be find by navigating to question_regex.list table.

Please mark the responses as helpful/correct, if applicable.

Regards,
Muhammad