Computed Fields
If you're a Fusion user, this feature is not available in the Components or Drawings workspaces. Learn more about system workspaces.
Computed fields are Item Detail fields that automatically calculate values based on formulas you define. They update in real time as data changes and can include custom UI elements using HTML. Along with appearing in Item Details, computed fields can also be used in workspace views and reports.
Computed fields can help you:
- Highlight important information with conditional formatting and color coding
- Display KPIs using graphics, charts, and visual indicators
- Drive adoption with improved usability
- Reduce custom scripting by handling complex logic through formulas
Capabilities
Basic capabilities
Computed fields support a wide variety of basic capabilities:
- Mathematical operations:
COST_1 + COST_2
- Boolean operations:
WHEN (MEASURED_WEIGHT > WEIGHT)
orWHEN (CONFIRMED is FALSE)
- Concatenation:
LENGTH|| ' mm '
- Conditional statements:
CASE WHEN (PRIORITY is null) THEN ‘?’ WHEN (PRIORITY = 1) THEN 'Low', WHEN (PRIORITY = 2) THEN ‘Medium’, ELSE ‘High'
- Null checking:
WHEN(PRIORITY is not null)
Advanced capabilities
Computed fields also support a wide variety of advanced capabilities:
- Rounding:
ROUND(CONFIRMED_EFFORT - PLANNED_EFFORT, 0)
- Rounding to zero when value is null:
coalesce(LABOUR_COST,0)
- Casting:
CAST(COST as FLOAT)
- Date calculations:
DATE_PART('day', CURRENT_DATE – LAST_MODIFICATION_DATE)
- String length calculations:
WHEN LENGTH(TITLE) < 10 THEN
- HTML and visual elements:
- Style and formatting:
<span style=“color:red“>High</span>
- iframe integration:
<iframe src=“www.google.com“>
- PDF integration:
<object style="width:100%;height:500px“ data="'||DRAWING_URL||'&inline&thumbnail" type="application/pdf"></object>
- Display images:
<img style="height:60px" src="https://yt3.ggpht.com/-JP7BQdvTP60/AAAAAAAAAAI/AAAAAAAAAAA/zvpjFigLSis/s900-c-k-no-mo-rj-c0xffffff/photo.jpg">
- Links:
<a "href=www.google.com" target=“_blank“>Search</a>
- Style and formatting:
For more detailed examples, refer to Examples of Computed Field Formulas
Create a computed field
You can create a new computed field or convert an existing field into a computed one.
- From the main menu, go to Administration > Workspace Manager.
- Select your workspace, then open the Item Details tab.
- Do one of the following:
- Click Create a Field to add a new computed field.
- Click Edit a Field to modify an existing field.
- In the dialog that appears, click Make this a Computed Field.
- Enter your formula in the Computed Field Formula field.
- Click Save.
Limitations
Be aware of these limitations when working with computed fields:
- Workflow status: Computed fields cannot reference workflow state information
- DMSID: System identifiers are not accessible
- Workspace name: Computed fields cannot reference workspace name
- Picklist values: Computed fields cannot access picklist data by value
- Computed field dependencies: Computed fields cannot use other computed fields in calculations
- Variables: Variables are not supported
- Item creation: Computed fields cannot be rendered in "Create" dialogs