When you define an sfdcDigest transformation, you set the action attribute to sfdcDigest and specify the parameters for the object and fields
that you want to extract. Optionally, you can also specify parameters to filter the records
extracted from the Salesforce object.
Parameters
You can specify parameters in the following sections of the sfdcDigest node: parameters,
fields, and filterConditions.
This table describes the parameters in the parameters
section.
| Parameter |
Required? |
Value |
| object |
Yes |
API name of the Salesforce object from which you want to extract data. This
object is the input source for this transformation. The sfdcDigest transformation
doesn’t support extraction from all Salesforce objects. |
| incremental |
No |
Performs an incremental sync, which extracts only changes to the Salesforce
object since the last dataflow run. Valid values: true or false. Incremental sync:
- Is available if you have enabled data sync.
- Isn’t supported for Salesforce big objects.
|
| fullRefreshToken |
No |
Performs a one-time full extraction to synchronize the data in the dataset with
data in the Salesforce object. Specify any value for this parameter.
Incremental sync is available if you have enabled data
sync.
|
| fields |
Yes |
An array of names of all fields from which you want to extract data from the
specified Salesforce object. The sfdcDigest transformation doesn’t support
extraction from all field types.
See Field Attributes.
|
| filterConditions |
No |
A filter that restricts the records extracted from the specified Salesforce
object. The sfdcDigest transformation extracts all records from the Salesforce
object for which the filter is true. You can specify a structured or advanced
filter.
See Filter Conditions Parameters.
|
| complexFilterConditions |
No |
For advanced filters only. A SOQL WHERE clause used to filter records extracted
from the specified Salesforce object. |
Field Attributes
The following table describes the attributes in the fields section. It also describes optional attributes that you can provide to
override the field metadata. You can override the metadata that the sfdcDigest
Transformation transformation extracts from a Salesforce object to make the data appear
differently in a dataset. For example, CRM Analytics can add a default value to records that
have missing values for a field. If you don’t override the values, CRM Analytics gets the
values from Salesforce.
| Attribute |
Required? |
Value |
| name |
Yes |
API name of the field in the Salesforce object that you want to include in the
dataset. You can specify multiple fields. |
| defaultValue |
No |
Used for text and numeric fields that can be null. Numeric fields can have a
literal null, while text fields can have
“null”. A default value replaces a null
value for the specified field. Enter a string value.
Example: "defaultValue": "0"
|
| type |
No |
CRM Analytics field type associated with the specified field. Valid types are
Text, Numeric, or Date. Any value, including numeric values, can be Text. For
example, by default, fiscal quarter from Salesforce objects is Number. However, you
can change it to Text. Specify a type to override the type determined by CRM
Analytics.
Example: "type":
"Text"
You can’t change a field’s type to Numeric or
Date.
|
| fiscalMonthOffset |
No |
For date fields only. The difference, in months, between the first month of the
fiscal year and the first month of the calendar year (January). For example, if the
fiscal year starts in January, the offset is 0. If the fiscal year starts in
October, the offset is 9.
Example: "fiscalMonthOffset": 9
This attribute also controls whether CRM
Analytics generates fiscal date fields. To generate fiscal date fields, set
fiscalMonthOffset to a value other than
0.
CRM Analytics doesn’t support fields with different fiscalMonthOffset values in the same dataset. Using
different fiscalMonthOffset values can
produce unexpected results when you filter by relative fiscal date ranges. We
recommend that you set the same value for all fiscalMonthOffset attributes in a dataset.
|
| isYearEndFiscalYear |
No |
For date fields only. Indicates whether the fiscal year is the year in which
the fiscal year ends or begins. Because the fiscal year can start in one calendar
year and end in another, you must specify which year to use for the fiscal year.
- If true, then the fiscal year is the year in which the fiscal year ends. The
default is true.
- If false, then the fiscal year is the year in which the fiscal year
begins.
Example: "isYearEndFiscalYear":
true
This field is relevant only when fiscalMonthOffset is greater than 0.
CRM Analytics doesn’t
support fields with different isYearEndFiscalYear values in the same dataset. Using different
isYearEndFiscalYear values can produce
unexpected results when you filter by relative fiscal date ranges. We recommend
that you set the same value for all isYearEndFiscalYear attributes in a dataset.
|
| firstDayOfWeek |
No |
For date fields only. The first day of the week for the calendar year and, if
applicable, fiscal year. Use 0 to set the first day to be Sunday, 1 to set the first
day to be Monday, and so on. Use -1 to set the first day to be on January 1. The
default is -1.
Example: "firstDayOfWeek":
0
CRM Analytics doesn’t support fields with different firstDayOfWeek values in the same dataset. Using
different firstDayOfWeek values can produce
unexpected results when you filter by relative week date ranges. We recommend that
you set the same value for all firstDayOfWeek
attributes in a dataset.
|
| isMultiValue |
No |
For text fields only. Indicates whether the specified field has multiple
values.
Example: "isMultiValue":
false
|
| multiValueSeparator |
No |
For text fields only. Single character used to separate multiple values in the
specified field when isMultiValue equals true. This value defaults to a semicolon
(;) if you do not specify a value and isMultiValue equals true. Set to null when
isMultiValue equals false.
Example: "multiValueSeparator": ";"
|
| precision |
No |
Example: "precision": 10
|
| scale |
No |
Example: "scale": 2
|
Filter Conditions Parameters
The following table describes the structured filter parameters in the filterConditions section. These parameters do not apply to
advanced filters.
| Parameter |
Required? |
Value |
| field |
No |
The field in the Salesforce object on which you want to apply a filter
condition. Each filter condition in a structured filter uses the following syntax:
{
"field": "<field name>",
"operator": "<operator>",
"value": "<value>",
"isQuoted": true|false}
|
| operator |
No |
The purpose depends on the context.
operator can be used as a comparison
operator–like =, <, and IN–that compares the field value
against a constant value.
operator can also be used as a logical
operator (AND, OR, or NOT) that links multiple filter conditions together.
In the example below, the bold operator
is the logical operator. The other instances of operator are comparison
operators.
"filterConditions": [
{
"operator": "OR",
"conditions": [
{
"field": "StageName",
"operator": "=",
"value": "Closed Won"
},
{
"field": "Probability",
"operator": ">=",
"value": "90"
}
]
}
]
|
| value |
No |
The value used in a filter condition. |
| isQuoted |
No |
Indicates whether you quoted the string value in a filter condition.
Example
with quoted values:
"filterConditions": [
{
"field": "StageName",
"operator": "IN",
"value": "('Closed Won', 'Closed Lost')",
"isQuoted": true
}
]
Example with non-quoted values:
"filterConditions": [
{
"field": "StageName",
"operator": "IN",
"value": ["Closed Won", "Closed Lost"],
"isQuoted": false
}
]
If you don’t include isQuoted for a filter on a string value,
CRM Analytics assumes that the string value is not quoted and adds the quotes for
you.
|
| conditions |
No |
Use to specify a logical operator to link multiple filter conditions
together. |