Default versus calculated field values

It is an easy mistake to make, to think that giving a table column (AKA field) a default value, and giving it a calculated value, have effectively the same result. However, this is not the case. Default and calculated values behave quite differently, and should be used for quite different purposes.

In this section, we'll explore what each are (and are not) meant to be used for, and the difference in behavior between them. We'll also discuss field calculation scripts, and best practices regarding default and calculated fields.

Default values

Default field values can be quite simple: a string, an integer, or whatever data-type matches the field's type.

You can get a fair bit more advanced with it though, by using ...

Get Learning ServiceNow now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.