Newer Version Available

This content describes an older version of this product. View Latest

FormulaFunction

Represents a function used when building a formula, including examples and uses. This object is available in Tooling API version 39.0 and later.

Supported SOAP Calls

In API version 45.0 and later, only users with the “ViewSetup and Configuration” permission can access FormulaFunction or FormulaFunctionCategory.

Note

query()

Supported REST HTTP Methods

GET

Fields

Field Details
Category
Type
FormulaFunctionCategory
Properties
Filter, Group, Nillable, Sort
Description
TheFormulaFunctionCategory to which the formula belongs.
CategoryId
Type
string
Properties
Filter, Group, Nillable, Sort
Description
The ID of the FormulaFunctionCategory.
Description
Type
string
Properties
Filter, Group, Nillable, Sort
Description
Description of the formula function.
DurableId
Type
string
Properties
Filter, Group, Nillable, Sort
Description
Unique identifier for the field. Always retrieve this value before using it, as the value isn’t guaranteed to stay the same from one release to the next. To simplify queries, use this field.
ExampleString
Type
string
Properties
Filter, Group, Nillable, Sort
Description
Describes the function and what arguments you can use with it.
IsAllowedInEntityContext
Type
boolean
Properties
Filter, Group, Nillable, Sort
Description
Indicates whether you can use the formula function on an Entity (true) or not (false). For example, you cannot use the PRIORVALUE function in a custom Account formula field.
IsAllowedInFlowContext
Type
boolean
Properties
Filter, Group, Nillable, Sort
Description
Indicates whether the formula function is allowed in a Flow (true) or not (false).
IsAllowedInVisualforceContext
Type
boolean
Properties
Filter, Group, Nillable, Sort
Description
Indicates whether the formula function is allowed in Visualforce (true) or not (false).
Label
Type
string
Properties
Filter, Group, Nillable, Sort
Description
The formula function label that appears in the user interface.
Name
Type
string
Properties
Filter, Group, Nillable, Sort
Description
The name of the formula function.

FormulaFunctionCategory Metadata

Field Name Details
DurableId
Type
string
Properties
Filter, Group, Nillable, Sort
Description
Unique identifier for the field. Always retrieve this value before using it, as the value isn’t guaranteed to stay the same from one release to the next. To simplify queries, use this field.
Functions
Type
QueryResult
Properties
Filter, Group, Nillable, Sort
Description
A list of functions that belong to the FormulaFunctionCategory.
Label
Type
string
Properties
Filter, Group, Nillable, Sort
Description
Label of the FormulaFunctionCategory that appears in the user interface.
Name
Type
string
Properties
Filter, Group, Nillable, Sort
Description
Name of the FormulaFunctionCategory.

Query Examples

To get all the functions in FormulaFunction using REST:
1req.setEndpoint('http://instance.salesforce.com/services/data/v45.0/tooling/query?q=SELECT+label+FROM+FormulaFunction );
2req.setMethod('GET');
To get the DurableID of a function category using SOQL:
1SELECT DurableID FROM FormulaFunctionCategory
To get all the categories and their functions using SOQL:
1SELECT Name, Label, (SELECT Name, Label, Description, ExampleString FROM Functions) FROM FormulaFunctionCategory