Add calculated fields
This page provides a guide on how to add calculated fields to outputs in Upsolver.
Last updated
This page provides a guide on how to add calculated fields to outputs in Upsolver.
Last updated
You can add calculated fields to lookup tables and outputs.
Calculated fields are fields based on a function of one or more fields. These can be a combination of built-in functions and your own Python functions.
If the calculated field results in a boolean response, you can define whether the resulting calculation should be saved as a whitelist filter or a blacklist filter.
1. Click Add Calculated Field or under the Calculated Fields tab, click the add icon.
See: Functions to learn more about a specific calculated field.
2. Click Select next to the desired calculated function.
3. From the dropdown, select the values to use for each required input. You can also click on the hierarchy iconto review the available fields in your data. Additionally, click on the add iconto add another calculation within this function.
4. If the calculated field results in a boolean response, select whether the Filter Type is:
Whitelist: if result True
, keep record
Blacklist: if result True
, discard record
Once saved, the resulting filter will appear in the Filters tab under Whitelist Filters or Blacklist Filters respectively.
5. Select where to locate the calculated field (e.g. root, data) and name this field. This operation joins the input arrays using a cartesian product.
The fields are typically added at the root level, however on occasion you can opt to co‑locate a field with another element in the hierarchy.
6. Click Preview to review your calculated field before saving; a Field Content Samples panel will appear on the right.
7. To add columns to the preview, click Choose Columns and select the desired columns. Then click Update.
Toggle from From to Code to review the calculated field as code.
8. Click Save.
You have now successfully created a calculated field.