Loading
Sales Performance Management
Table of Contents
Select Filters

          No results
          No results
          Here are some search tips

          Check the spelling of your keywords.
          Use more general search terms.
          Select fewer filters to broaden your search.

          Search all of Salesforce Help
          quotas

          quotas

          Returns a list of quota values from a quota table in Salesforce Spiff. The quota values are for a specific user in a specific time period.

          Required Editions

          Available in: both Salesforce Classic (not available in all orgs) and Lightning Experience
          Available in: Enterprise, Unlimited, and Developer Editions
          Available for an additional cost in: Professional Edition with Web Services API Enabled

          Syntax

          quotas(users_or_users, quota_name, start_date, end_date)

          Arguments

          Argument Required? Description
          user or users Optional

          The user or list of users to return quota values for.

          • To return quota values for all users, use the null keyword, =quotas(null).
          • To return quota values for the current rep, use the rep keyword, =quotas(rep). This value is the default behavior when you don't specify a user or list of users.
          • To return values for a different user, reference the rep's User object.
          • To return values for an entire team, use the members() function.
          quota_name Optional The name of a quota from a quota table, enclosed in double quotes. This argument updates automatically when the name of the quota table changes. To specify a list of multiple quota tables, enclose the list in brackets with comma-separated values.
          start_date Optional The lower bound of the date range to get quota values for. This argument supports any date functions. To specify a date as a string in YYYY-MM-DD format, use the date() function and enclose the string in double quotes.
          end_date Optional The upper bound of the date range to get quota values for. This argument supports any date functions. To specify a date as a string in YYYY-MM-DD format, use the date() function and enclose the string in double quotes.

          Considerations

          Combine the sum() function with the quotas() function so you can sum a list of quota values.

          Examples

          Return quota values for a specific user, Teresa Lee. Create a data filter on the User object that contains only the rep, and use the single() function within the quotas() function to select the user from the data filter's list.

          =quotas(single(TeresaLee), "CorporateAEQuarterlyQuota")

          Return quota values for the current rep for the calendar year.

          =quotas(rep, "CorporateAEQuarterlyQuota", beginning_of_year(statement_period.start_date), end_of_year(statement_period.end_date))

          Return values for all users from multiple quota tables.

          quotas(null, ["CorporateAE", "EnterpriseAE"])

          Return values for the current rep for the current quarter.

          quotas(rep, "CorporateAE", beginning_of_quarter(statement_period.start_date), end_of_quarter(statement_period.end_date))

          Return quarter-to-date quota values.

          quotas(rep, "CorporateAE", beginning_of_quarter(statement_period.start_date), statement_period.end_date)

          Sum quotas in the fiscal year.

          =sum(quotas(rep, "CorporateAE", StartOfFiscalYear, EndOfFiscalYear), amount)

          Sum all team member quotas.

          TeamManaged =choose(1, direct_manager_of(BeginningOfPeriod, EndOfPeriod))
          UsersInManagedTeam =users_in_team(TeamManaged, BeginningOfPeriod, EndOfPeriod)
          SumTeamQuotas =sum(quotas(UsersInManagedTeam, "QuotaTable", BeginningOfPeriod, EndOfPeriod), amount)

          Sum team member quotas in different currencies.

          sum(quotas(members("team"), "QuotaTable", beginning_of_quarter(statement_period.start_date), end_of_quarter(statement_period.end_date)), convert_currency(amount, "USD", statement_period.start_date))
           
          Loading
          Salesforce Help | Article