Skip to main content

Formula examples: totals, text, dates and status

Copy-ready formulas for totals, text, dates, scores from choices, an overall status and sums across linked records.

Written by Peter Novosel

These are formulas you can copy into a Formula field and adapt. Each one solves a common job, shows the formula, and says what it gives back.

Here is the test: find the example closest to what you want, copy it, and change the names in square brackets to your own field names.

Example: every formula here uses a vendor risk program, with Vendors, Contracts, Findings and Controls tables. The same patterns work for any table.

The Advanced Editor of the Inherent Risk Score field, with the formula in the editor.

The Advanced Editor of the Inherent Risk Score field, with the formula in the editor.

Plan Availability

All plan types.

Permissions

Administrators and Solution Managers create and change formulas in the solutions they manage.

Platform

Web

Related Reading


Using an example

  1. Open the Formula field's settings and turn on Advanced Editor.

  2. Paste the formula into the editor.

  3. Replace each name in square brackets with a field from your table. The Fields tab on the left lists them.

  4. Select Update Field, or Add Field on a new field.

Tip: Spaces and line breaks between parts of a formula are ignored. Split a long formula over several lines so it is easier to read.


Totals and math

Multiply two fields. Total Contract Value from a yearly value and a number of years:

[Annual Contract Value] * [Contract Years]

The result updates when either field changes.

Add a percentage. A value with a 10 percent uplift:

[Annual Contract Value] * 1.1

Text

Join fields into one label. Contract Label from the vendor and the contract number:

[Vendor Name] + " - " + [Contract Number]

CONCAT([Vendor Name], " - ", [Contract Number])

Both give "Acme Payroll - CNT-2026-0041". The + joins text when any part is not a number.

Count the characters. Summary Length, to keep a finding summary under 200 characters:

LENGTH([Finding Summary])

Counting

Count the choices picked. How many data types a vendor can see, from a Multiple Select field:

COUNT([Data Types Accessed])

Dates

Days between two dates. How close a remediation came to its deadline:

DATEDIFF([Remediation Due], [Closed On], "days")

The unit can be minutes, hours, days, weeks, months (30 days) or years.

Days since a record was created. How long a finding has been open:

DATEDIFF([First Created], NOW(), "days")

Whole weeks between two dates

ROUND(DATEDIFF([Start], [End], "weeks"), 0)

Date Based Formulas has more, such as working days and the last day of a month.


Scores from choices

A Single Select or Multiple Select field can give each choice a number. Turn on Include Value in the field's Manage List. A formula reads the number with NUMERICVALUE.

A priority from two ratings. A Findings table has Severity (Low 1, Medium 3, High 5) and Reach (Few 1, Many 3, All 5). Priority multiplies them:

IF((NUMERICVALUE([Severity]) * NUMERICVALUE([Reach])) >= 15, "High", IF((NUMERICVALUE([Severity]) * NUMERICVALUE([Reach])) >= 9, "Medium", "Low"))

A High finding that reaches Many users scores 15, so it is High. A Medium finding that reaches Many scores 9, so it is Medium.

A total from many choices. Inherent Risk Score adds the numbers of every data type a vendor can see:

SUM(NUMERICVALUE([Data Types Accessed]))

Note: On a Multiple Select field, NUMERICVALUE returns a list, one number per choice. On its own it shows Invalid Formula. Wrap it in SUM.


Status from conditions

An overall status from two Single Select fields. A Controls table has Tester Status (Pending, In Progress, Complete) and Reviewer Status (Pending, Approved, Rejected). Overall Status works out the stage:

IF([Tester Status] = "Pending", "New", IF([Tester Status] = "In Progress", "Testing", IF(AND([Tester Status] = "Complete", [Reviewer Status] = "Pending"), "Ready for Review", IF(AND([Tester Status] = "Complete", [Reviewer Status] = "Approved"), "Passed", IF([Reviewer Status] = "Rejected", "Failed", "Check the statuses")))))

Each IF tests one case. AND requires both conditions. The last value catches anything unexpected, with a message people can act on.


Across linked records

Add up linked values that meet a condition. A vendor's Open Findings Score adds the severity scores of its linked findings that are still open:

SUMIF([Findings].[Status] = "Open", [Findings].[Severity Score])

The result is one number per vendor, ready to sort and filter on. See Reference data from other tables in a formula.


Frequently asked questions

How do I combine first and last name?

[First Name] + " " + [Last Name], or CONCAT([First Name], " ", [Last Name]).

How do I count the days from a date to today?

DATEDIFF([Your Date], NOW(), "days"). Swap the two dates to count forward to a future date.

How do I work out an age from a birthdate?

ROUND(DATEDIFF([Birthdate], TODAY(), "days")/365.25-0.49, 0) rounds down, so the age changes on the birthday.

How do I multiply a Currency field by a Percent field?

Multiply them: [Price] * [Discount]. Check the result on one record, and divide by 100 if the percent comes through as a whole number.

Where is the full list of functions?

In Formula Functions & Operators.

Last verified 31 Oct 2026.

Did this answer your question?