Loading
Salesforce Enforces New Security Requirements in Summer 2026Read More
Tableau Semantics
Write a Formula in a Calculated Field

Write a Formula in a Calculated Field

Formulas define how a calculated field is computed. How a formula is written is called its syntax. A formula may contain functions, fields, operators, literal expressions, parameters, or comments.

Required Editions

Available in: All editions supported by Data 360. See Data 360 edition availability.
User Permissions Needed
To build a formula:

Permission set:

  • Data Cloud Architect

AND

Semantic Models object

  1. In Data Cloud, on the Semantic Layer tab, select a data model.
  2. Open the New Calculated Field or Edit Calculated Field window:
    1. From the New dropdown, select Calculated Field. Or,
    2. Select a calculated field in the left pane.
  3. Configure the field settings.
  4. In the calculated field window, click the Formula box.
  5. Write your formula. You can type out exactly what you want or insert a function or field.
    1. To insert a function, click the Functions tab and expand the appropriate section. Select the function that you want to use and click Insert. Replace the placeholder syntax as appropriate.
    2. To insert a field, click the Field tab and expand the appropriate data object. Select the field that you want to use and click Insert.
  6. Validate your formula to check for errors.
  7. Save the calculated field.
Note
Note If the formula refers to multiple data objects, the calculated field appears under Calculated Fields in the left pane. If the formula refers to a single data object, the calculated field appears as a field in that data object — expand the object to view it.
 
Loading
Salesforce Help | Article