Find your people. Pick a challenge. Ship something real. The CreatorCon Hackathon is coming to the Community Pavilion for one epic night. Every skill level, every role welcome. Join us on May 5th and learn more here.

What is CONSTANT and use of Constant?

Sid_Takali
Kilo Patron

I'm new in servicenow and trying to educate myself. I wants to know What is CONSTANT and what is the use of Constant?

Thanks!

1 REPLY 1

Sandeep Rajput
Tera Patron

Constant: A constant in ServiceNow is a variable whose value never changes after the initialisation. 

 

There are two ways to define constant within ServiceNow.

1. Using properties: Define a property key value pair within System property and use its value within your code.

2. Create a Script Include: Create a separate include containing your constant variables (misnomer) and use it across your business rules and script includes.

 

Hope this helps.