---
schema_version: "1"
id: 3b383b3c66c5cc6cfc11a27fc1ce00c8ca042e2b33679f03f610da2b9738b655
title: Dot Syntax in Salesforce Spiff Formulas
collection: admin
version: current
locale: en-us
portal_url: https://docs.salesforce.com/admin/current/en-us/sales/264-0-0/spiff_dot_syntax.md
canonical_url: https://help.salesforce.com/s/articleView?id=sales.spiff_dot_syntax.htm&release=264.0.0&type=5
source_site: help.salesforce.com
content_type: documentation
content_hash: 8b5bcc698c6fa26b641c7fce7f72cb6f39a30eced911580b3a9b5aced448c138
description: Functions and formulas in Salesforce Spiff use dot syntax for efficiently referencing fields, relationships, Team object details, and data from multiple records.
products:
  - Sales Cloud
  - Sales Enablement
release: "264"
---
# Dot Syntax in Salesforce Spiff Formulas

Functions and formulas in Salesforce Spiff use dot syntax for efficiently referencing fields, relationships, Team object details, and data from multiple records.

### Required Editions

<table class="slds-table slds-table_bordered slds-max-medium-table_stacked slds-m-bottom_small edition"><colgroup><col></colgroup><tbody><tr class=""><td class="slds-cell-wrap" style="vertical-align:top;">Available in: both Salesforce Classic (not available in all orgs) and Lightning Experience</td></tr><tr class=""><td class="slds-cell-wrap" style="vertical-align:top;">Available in: <strong>Enterprise</strong>, <strong>Unlimited</strong>, and <strong>Developer</strong> Editions</td></tr><tr class=""><td class="slds-cell-wrap" style="vertical-align:top;">Available for an additional cost in: <strong>Professional</strong> Edition with Web Services API Enabled</td></tr></tbody></table>

For example, a worksheet calculation named LargestDealInPeriod has this formula for returning the largest deal record within a specific period.

```
=choose(1, sort(ClosedInPeriod, DealAmount, -1))
```

The ClosedInPeriod data filter returns all deals closed in the period, and the `sort()` function arranges the list of deals by DealAmount, from highest to lowest. The `choose()` function selects the first record.

This calculation doesn't show anything in the worksheet because it returns a record, not a value. The referenced record contains multiple fields with different values. Reference a specific field's value with dot syntax.

- To show the close date of the largest deal, use `=HighestDealInPeriod.CloseDate`.
- To show the amount of the largest deal, use `=HighestDealInPeriod.DealAmount`.
- To show the owner of the largest deal, use `=HighestDealInPeriod.OwnerName`.

#### See Also

- [choose](https://help.salesforce.com/s/articleView?id=sales.spiff_function_ref_choose.htm&release=264.0.0&type=5 "Returns a value from a list based on a specified index in Salesforce Spiff. List values in Spiff aren't sorted by any default order. To make sure that you select the appropriate value, combine this function with sort() so that you sort the list values before you select a specific index.")
- [filter](https://help.salesforce.com/s/articleView?id=sales.spiff_function_ref_filter.htm&release=264.0.0&type=5 "Further filters records in a Salesforce Spiff data filter, list, or relationship and returns a list of records that match a specified condition. This function helps refine an existing data filter.")
- [sort](https://help.salesforce.com/s/articleView?id=sales.spiff_function_ref_sort.htm&release=264.0.0&type=5 "Organizes records in a Salesforce Spiff data filter by a date, string value, or number value and returns a list of sorted records.")