Advanced calculations
As a PaySuiteCompensation Management feature, calculated columns allow administrators to perform advanced calculations directly within compensation rounds. Using formula-based expressions, calculated columns can aggregate values, apply conditional logic, and reference a wide range of fields from across the round, removing the need for manual data preparation outside the system.
Calculated columns are set up in the Team planner view, accessed from the compensation round configuration wizard. To learn more about compensation rounds, see Creating a compensation round.
Creating a calculated column
As an administrator, you can add a calculated column to a compensation round. To do so, proceed as follows:
In the Team planner view step of the compensation round configuration wizard, click the Create button in the top-right corner of the column list.
-
When the contextual menu appears, select Calculated column, as shown below:
Calculated column entry point in the Team planner view
The Calculated column drawer opens on the right side of the page, as illustrated in the following picture:
Calculated column drawer
Enter a Column name and a Code.
Choose the column output Type from the drop-down list – Decimal for numeric results, String for text results, or Boolean for true/false results.
Optionally, select a Header color to visually group or highlight the column in the compensation grid.
If you chose Decimal as the output type, configure the following additional options:
Decimal precision: Define the number of digits to display after the decimal separator. The default is 2.
-
Enable currency in the Calculation section: Toggle on to activate currency support for the column. When enabled, select a Currency source: Data model (currency of the exact compensation element), All currencies (any currency available for the organization), or Comp round currency (currency of the compensation round). For the Data model and All currencies, select the Currency field from the drop-down list. The figure below presents the Calculation section:
Calculation section of the Calculated column drawer
-
In the Calculation section, configure the following:
-
Type of the Formula: Select Non-conditional or Conditional. See Formula types for details.
For a non-conditional formula, enter your expression directly in the Formula field.
For a conditional formula, use one or more numbered condition blocks, each consisting of an If field for the condition and a Then field for the outcome. Click + Add condition to add more blocks, and fill in the Else field to define the fallback outcome. Copy or delete your conditions by clicking the and icons.
With both formula types, you can press Control + Space to trigger autocomplete suggestions for properties and functions. You can also click Learn more to access the contextual menu with properties, keyboard shortcuts, or the formula builder help displayed in a drawer on the right of the screen.
To switch to the full-width editing environment, click Open calculation workspace, as shown in the following illustration:
Accessing the calculation workspace
For more on the calculation workspace, go to the Calculation workspace below.
-
Click Apply to save your changes.
Viewing calculated columns in the Planner
As a manager or HRBP, you can view calculated columns in the Planner. To do so, proceed as follows:
Go to Planner > Compensation and click the name of the relevant compensation round in the list. You are redirected to the Comp review tab.
-
In the table of workers, calculated columns are marked with the icon next to the column name. Hovering over the icon displays a tooltip confirming that this is a calculated column, as you can see in the following picture:
Calculated columns in the Planner
When you click the icon, a drawer with the formula configuration is displayed on the right, reflecting how the calculation result was derived. In the drawer, you can also find the Learn more button, with the contextual menu including Properties, Keyboard shortcuts, and Help, as shown below:
Calculated column formula drawer
Calculated columns can be driven by other columns in the Planner. For instance, a conditional calculated column can be linked to a custom column. When you update the value in the custom column for a worker, the calculated column output updates accordingly.
Formula types
Calculated columns support two types of formula:
Non-conditional formulas, which produce a result based on a single expression, with no branching logic. For example, in a Total Amount calculated column, a non-conditional formula can be used to sum all compensation element proposal values to produce a total compensation figure.
-
Conditional formulas, which use If / Then / Else logic to return different values depending on whether a condition is met. For instance, a custom column called Promotion with a "yes"/"no" selection can drive a conditional calculation. When the user sets the value to "yes" for a worker in the formula editor, a defined amount is automatically added to the worker's total compensation.
The following illustration presents input fields for the conditional formula:
Conditional formula editor in the Calculated column drawer
Calculation workspace
The calculation workspace provides more space for building and editing formulas. It is designed to support both conditional and non-conditional formulas efficiently. The picture below shows how the workspace is displayed on the screen:
Calculation workspace
The Calculation workspace page consists of four main areas.
On the left-hand side, a searchable Functions panel lists available functions and groups them by category: Aggregation, Conditional, DateTime, Math, and String, as defined in the Supported functions section of this article. Click a category to expand it and browse its functions. Each category item includes a short description that becomes visible when clicking the icon next to the item name. You can also click the icon to insert your chosen item into the formula directly from the panel. Additionally, the entire panel can be collapsed to maximize the editing area by clicking the icon in its top-right corner.
At the top, the operators bar displays the logical and arithmetic operators available for formula construction, including AND, OR, true, false, comparison operators, and arithmetic symbols. Operators also have built-in tooltips with descriptions and usage examples. On the right, there is the Calculation guide button. Click it to explore useful tips for creating your formula, such as:
Calculation guide tip
In the center, the Formula input serves as the main editing area where you write your expression. Press Control + Space on your keyboard for auto-suggestions. Available data sources and functions appear in a drop-down list with their types and descriptive tooltips, so you can select the right one without leaving the editor. Real-time validation below the formula input field highlights errors as you type, allowing you to correct them incrementally before saving.
At the bottom, the Properties panel specifies all fields available for use in the formula, organized by source: DataModel, RoundCalculations, and RoundInputs, which we describe in detail in Data sources. Use the search bar to locate a specific field by property name. You can also expand the data source by clicking its name to view listed fields. Each field entry includes a type, the icon that shows a description when clicked, and the icon to add the field into the formula writing area, as presented below:
Properties panel with a list of fields
The panel can be collapsed when not needed by clicking the icon in its top-right corner.
Once formula editing is complete, click the Close button to return to the Calculated column configuration in the drawer.
Data sources
Formulas can reference fields from three sources, all accessible from the Properties panel in the Calculation workspace:
DataModel: Fields from the underlying data model.
RoundCalculations: Calculated fields and results from other round configuration steps.
RoundInputs: Fields specific to the round, such as proposals and custom fields.
The following fields are available within these sources for use in formulas:
Calculations – based on other calculated fields
Custom fields – user-defined fields associated with the round
Eligibility – eligible flag and eligibility rule name
Budget – budget output value and rule name
Guidelines – guideline values, flags, and rule name
Guaranteed amount – guaranteed amount output and rule name
Conditional formatting – conditional formatting rule name
Supported functions
The Calculation workspace page organizes functions into five categories:
Aggregation
Function |
Description |
Parameters |
Return Type |
Example |
|---|---|---|---|---|
AVG |
Returns the average of all provided numbers |
array: Decimal (variadic) |
Decimal |
AVG(10, 5, 8) → 7.6 |
MAX |
Returns the maximum value from a list of numbers |
array: Decimal (variadic) |
Decimal |
MAX(10, 5, 8) → 10 |
MIN |
Returns the minimum value from a list of numbers |
array: Decimal (variadic) |
Decimal |
MIN(10, 5, 8) → 5 |
SUM |
Returns the sum of all provided numbers |
array: Decimal (variadic) |
Decimal |
SUM(10, 5, 8) → 23 |
Conditional
Function |
Description |
Parameters |
Return Type |
Example |
|---|---|---|---|---|
COALESCE |
Returns the first non-null value from a list of values |
values: Any (variadic) |
Any |
COALESCE(null, "default") → "default" |
IF |
Returns one value if condition is true, another if false |
condition: Boolean, ifTrue: Any, ifFalse: Any |
Any |
IF(true, "yes", "no") → "yes" |
ISNULL |
Checks if a value is null |
value: Any |
Boolean |
ISNULL(null) → true |
DateTime
Function |
Description |
Parameters |
Return Type |
Example |
|---|---|---|---|---|
DATE |
Creates a date from year, month, and day components |
year: Decimal, month: Decimal, day: Decimal |
Date |
DATE(2024, 1, 15) → 2024-01-15 |
DATE_ADD_DAY |
Add the given number of day to a date |
date: Date, days: Decimal |
Decimal |
DATE_ADD_DAY(STR_TO_DATE("2024-01-15"), 1) → 2024-01-16 |
DATE_DAY |
Returns the day component of a date |
date: Date |
Decimal |
DATE_DAY(STR_TO_DATE("2024-01-15")) → 15 |
DATE_MONTH |
Returns the month component of a date |
date: Date |
Decimal |
DATE_MONTH(STR_TO_DATE("2024-01-15")) → 01 |
DATE_TIME |
Creates a datetime from year, month, day, hour, minute, and second components in UTC |
year: Decimal, month: Decimal, day: Decimal, hour: Decimal, minute: Decimal, second: Decimal |
Date |
DATE_TIME(2024, 1, 15, 14, 30, 0) → 2024-01-15 14:30:00 |
DATE_TIME_TZ |
Creates a datetime in the specified timezone and converts it to UTC |
year: Decimal, month: Decimal, day: Decimal, hour: Decimal, minute: Decimal, second: Decimal, timezone: String |
Date |
DATE_TIME_TZ(2024, 1, 15, 10, 0, 0, "Eastern Standard Time") → 2024-01-15 15:00:00 UTC |
DATE_YEAR |
Returns the year component of a date |
date: Date |
Decimal |
DATE_YEAR(STR_TO_DATE("2024-01-15")) → 2024 |
STR_TO_DATE |
Converts a string to a date object |
dateString: String |
Date |
STR_TO_DATE("2024-01-15") → 2024-01-15 |
Math
Function |
Description |
Parameters |
Return Type |
Example |
|---|---|---|---|---|
ABS |
Returns the absolute value of a number |
number: Decimal |
Decimal |
ABS(-5) → 5 |
CEILING |
Rounds a number up to the nearest integer |
value: Decimal |
Decimal |
CEILING(3.2) → 4 |
FLOOR |
Rounds a number down to the nearest integer |
value: Decimal |
Decimal |
FLOOR(3.7) → 3 |
ROUND |
Rounds a number to the specified number of decimal places |
value: Decimal, decimals: Decimal |
Decimal |
ROUND(3.14159, 2) → 3.14 |
String
Function |
Description |
Parameters |
Return Type |
Example |
|---|---|---|---|---|
LOWER |
Converts text to lowercase letters |
text: String |
String |
LOWER("HELLO") → "hello" |
STRING_EQUALS |
Compares two strings for equality with optional case sensitivity |
text1: String, text2: String, ignoreCase: Boolean |
Boolean |
STRING_EQUALS("Hello", "hello", true) → true |
TRIM |
Removes leading and trailing whitespace from text |
text: String |
String |
TRIM(" hello ") → "hello" |
UPPER |
Converts text to uppercase letters |
text: String |
String |
UPPER("hello") → "HELLO" |