Display Formula
Use JSONata display formulas to show or hide fields and screen elements from current row, form, user, or context data.
Last updated
Use JSONata display formulas to show or hide fields and screen elements from current row, form, user, or context data.
A Display Formula is a conditional visibility rule. It lets Buzzy decide whether a field or screen element should be visible at runtime by evaluating a JSONata expression against the current data context.
Use Display Formula for progressive forms, conditional sections, role-specific interface hints, and workflow states. Do not use it as a security boundary. If a user must not access data, configure row access, field access, Private Data, Teams, or People settings instead.
Display Formula has two parts:
Show
Shows the field or element only when the formula evaluates to true.
Hide
Hides the field or element when the formula evaluates to true.
Buzzy evaluates the formula with JSONata. The formula can reference:
fields on the current row or form
_contextRow when the screen or form has a parent/current row context
_currentUrl in capture forms
_id for the generated or current row id
user._id, user.email, and user.highestRole
system fields such as userID, viewers, isLocked, and submitted
Fields with spaces or special characters must be wrapped in backticks:
`Favourite food type` = "Other"Strings use quotes, booleans use true and false, and formulas are case-sensitive.
Scenario: a form has a Selection field named Favourite food type with an Other option. You only want the free-text field to appear when the user selects Other.
Set the free-text field's Display Formula mode to Show, then use:
If the source field is a Checkboxes field, its value is an array. Use the JSONata in operator:
To show an element only to admins/authors:
To show an element to owners/authors, or to users who are not in the row's viewers list:
To show an element only to the row creator:
These examples are useful for interface behavior. They do not replace data permissions.
Show a field only when a row is not locked:
Or, more compactly:
Show a payment section only when payment is required and the permission/signature steps are complete:
Display Formula is used in two related places:
Datatable field settings
Current form or row data
Show or hide individual fields in a form, detail view, or result row.
Screen element visibility
Current screen, row, form, user, and context data
Show or hide containers, sections, form areas, empty-state branches, and other UI elements.
In the screen editor, the preview simulation panel can force Display Formula branches on or off so you can inspect both paths without changing live data.
If a formula does not behave as expected:
Confirm the field labels and internal names match the formula exactly.
Use backticks around labels with spaces or punctuation.
Check whether the source value is a string, number, boolean, array, or object.
Test both Show and Hide logic carefully. A Show rule hides the element when the formula is false; a Hide rule hides it when the formula is true.
Use the In-App Debugging to inspect screen context, bindings, fields, actions, and runtime errors.
For more JSONata syntax examples, see Formula language and jsonata.org.
Last updated
`Favourite food type` = "Other""Other" in `Favourite food type`user.highestRole = "owner" or user.highestRole = "author"(user.highestRole = "owner" or user.highestRole = "author") or $not(user._id in viewers)user._id = userIDisLocked = false$not(isLocked)isLocked = false
and $boolean(`Permission`)
and $boolean(`Signature`)
and (`Permission` = "Yes" ?
$boolean(`Emergency contact`)
and (`Payment required` = "Yes" ?
$boolean(`Payment options`)
: true)
: true)