Newer Version Available
BatchCalcJobDefinition
File Suffix and Directory Location
BatchCalcJobDefinition components have the suffix .batchCalcJobDefinition and are stored in the batchCalcJobDefinitions folder.
Version
BatchCalcJobDefinition components are available in API version 51.0 and later.
Special Access Rules
- Loyalty Management
- Financial Services Cloud
- Rebate Management
- Manufacturing Cloud
Fields
| Field Name | Field Type | Description |
|---|---|---|
| aggregates | BatchCalcJobAggregate[] | Collection of aggregate nodes in a data processing engine. |
| appends | BatchCalcJobUnion[] | Collection of append nodes in a data processing engine. |
| datasources | BatchCalcJobDatasource[] | Collection of data source nodes in a data processing engine. |
| description | string | Description of a data processing engine definition. |
| filters | BatchCalcJobFilter[] | Collection of filter nodes in a data processing engine. definition. |
| hierarchyPaths | BatchCalcJobHierarchyPath[] | Collection of hierarchy path nodes in a data processing engine definition. |
| isTemplate | boolean | Indicates whether this is a template data processing engine definition. |
| joins | BatchCalcJobSourceJoin[] | Collection of join nodes in a data processing engine. |
| label | string | The label of a data processing engine definition. |
| parameters | BatchCalcJobParameter[] | Collection of input variables in a data processing engine. |
| processType | BatchCalcProcessType (enumeration of type string) | The process type of a data processing engine. Valid values are:
|
| status | BatchJobDefinitionStatus (enumeration of type string) | Status of a data processing engine definition. Valid values are:
|
| transforms | BatchCalcJobTransform[] | Collection of data transformation nodes in a data processing engine. |
| writebacks | BatchCalcJobWritebackObject[] | Collection of writeback objects in which the results of the data processing engine are written back. |
Represents a collection of fields relating to an aggregate node in a data processing engine.
Fields
| Field Name | Field Type | Description |
|---|---|---|
| description | string | Description of an aggregate node. |
| fields | BatchCalcJobAggregateField[] | Required. Collection of aggregation fields. |
| groupBy | string[] | Required. Collections of fields used to group data in an aggregate node. |
| label | string | Required. Label of an aggregate node. |
| name | string | Required. Name of an aggregate node. |
| sourceName | string | Required. Name of the source node. |
Represents a collection of fields relating to an aggregation field in an aggregate node of a data processing engine.
Fields
| Field Name | Field Type | Description |
|---|---|---|
| aggregateFunction | BatchCalcJobAggregateFunction (enumeration of type string) | Required. Function used for aggregation. Valid values are:
|
| alias | string | Required. Name that subsequent nodes within the data processing engine use to refer to the aggregate field. |
| sourceFieldName | string | Required. Source node field on which the aggregate is calculated. |
Represents a collection of fields relating to a data source node in a data processing engine.
Fields
| Field Name | Field Type | Description |
|---|---|---|
| description | string | Description of a data source node. |
| fields | BatchCalcJobDatasourceField[] | Required. Collection of data source fields. |
| label | string | Required. Label of a data source node. |
| name | string | Required. Name of a data source node. |
| sourceName | string | Required. Name of a standard or custom object from which the data source node extracts data. |
| type | BatchCalcJobSourceType (enumeration of type string) | Required. Type of object for the source object field. Supported value is StandardObject. |
Represents a collection of fields relating to a source object field that are selected in the data source node of a data processing engine.
Fields
| Field Name | Field Type | Description |
|---|---|---|
| alias | string | Name that subsequent nodes within the data processing engine use to refer to the data source field. Required when the field name is lookup. |
| name | string | Required. Name of the field. This can be either of the following:
|
Represents a collection of fields relating to a filter node in a data processing engine.
Fields
| Field Name | Field Type | Description |
|---|---|---|
| criteria | BatchCalcJobFilterCriteria[] | Collection of filter criteria in a filter node. |
| description | string | Description of the batch calculation job filter. |
| filterCondition | string | Logic that is specified to apply the filter conditions. |
| filterParameterName | string | Name of the parameter of type filter. |
| isDynamicFilter | boolean | Indicates whether the filter criteria is dynamic. If value is set to True, filter criteria is passed in runtime with filterParameterName. |
| label | string | Required. Label of the filter node. |
| name | string | Required. Name of the filter node. |
| sourceName | string | Required. Name of the source node. |
Represents a collection of hierarchy path nodes in a data processing engine definition.
Fields
| Field Name | Field Type | Description |
|---|---|---|
| description | string | Description of the hierarchy path node. |
| hierarchyFieldName | string | Required. Field name that contains the hierarchy path. |
| isSelfFieldValueIncluded | boolean | Indicates whether self value is included in the calculated hierarchy path (True) or not (False). |
| label | string | Required. Label of the hierarchy path node. |
| name | string | Required. Name of the hierarchy path node. |
| parentFieldName | string | Required. Parent field name to calculate hierarchy path. |
| selfFieldName | string | Required. Self field name to calculate hierarchy path. |
| sourceName | string | Required. Name of the source node. |
Represents a collection of fields relating to a filter condition in a filter node in a data processing engine.
Fields
| Field Name | Field Type | Description |
|---|---|---|
| inputVariable | string | Name of the input variable used as a filter. |
| operator | BatchCalcJobFilterOperator (enumeration of type string) | Required. Operator that is specified in the filter condition. Valid values are:
|
| sequence | integer | Required. Sequence number used to refer the criteria in a filter node. |
| sourceFieldName | string | Required. Name of the field from the source node to apply the filter. |
| value | string | Value used to filter data from the source node. |
Represents a collection of fields relating to an input variable in a data processing engine.
Fields
| Field Name | Field Type | Description |
|---|---|---|
| dataType | BatchCalcJobParameterDataType (enumeration of type string) | Required. Data type of the parameter. Valid values are:
|
| defaultValue | string | Default value of the parameter. |
| description | string | Description of the batch calculation job parameter. |
| isMultiValue | boolean | Indicates whether the parameter has different values (True) or not (False). This field is supported only for the Text data type. |
| label | string | Required. Label of the batch calculation job parameter. |
| name | string | Required. Name of the batch calculation job parameter. |
Represents a collection of fields relating to a join node in a data processing engine.
Fields
| Field Name | Field Type | Description |
|---|---|---|
| description | string | Description of the join node. |
| fields | BatchCalcJobJoinResultField[] | Collection of fields in a join node. |
| joinKeys | BatchCalcJobJoinKey[] | Collection of mapping of fields from the primary source node and the second source node in a join node. |
| label | string | Required. Label of the join node. |
| name | string | Required. Name of the join node. |
| primarySourceName | string | Required. Name associated with the node as the primary source node. |
| secondarySourceName | string | Required. Name associated with the node as the secondary source node. |
| type | BatchCalcJobSourceJoinType (enumeration of type string) | Required. Type of join specified between the primary source node and secondary
source node. Valid values are:
|
Represents a collection of fields relating to a mapping of fields from the first source node and second source node in a join node of a data processing engine.
Fields
| Field Name | Field Type | Description |
|---|---|---|
| primarySourceFieldName | string | Required. Mapped field name of the primary source node. |
| secondarySourceFieldName | string | Required. Mapped field name of the secondary source node. |
Represents a collection of fields relating to a set of resultant fields in a join node of a data processing engine.
Fields
| Field Name | Field Type | Description |
|---|---|---|
| alias | string | Required. Name that subsequent nodes within the data processing engine definition use to refer to the resultant field. |
| sourceFieldName | string | Required. Name of field from the primary or secondary data source. |
| sourceName | string | Required. Source node of the primary or secondary data source. |
Represents a collection of fields relating to a data transformation in a data processing engine.
Fields
| Field Name | Field Type | Description |
|---|---|---|
| description | string | The description of the batch calculation job transform. |
| droppedFields | BatchCalcJobTransformDroppedField[] | The collection of dropped fields in a data transformation. Available when the transformation type is Slice. |
| expressionFields | BatchCalcJobTransformAddedField[] | The collection of formula fields in a data transformation. Available when the transformation type is Expression. |
| label | string | Required. The label of the batch calculation job transform. |
| name | string | Required. The name of the batch calculation job transform. |
| orderBy | BatchCalcJobOrderByField[] | A collection of fields that are used to sort the records within each partition group. |
| partitionBy | string[] | A group of fields that are used to partition the source data into partition groups. |
| sourceName | string | Required. Name of the source node. |
| transformType | BatchCalcJobTransformType (enumeration of type string) | Required. The type of transformation. Valid values are:
|
Represents a collection of fields relating to a dropped field in a data transformation of a data processing engine.
Fields
| Field Name | Field Type | Description |
|---|---|---|
| sourceFieldName | string | Required. Name of the field that is dropped. |
Represents a collection of fields relating to a formula in a data transformation of a data processing engine.
Fields
| Field Name | Field Type | Description |
|---|---|---|
| alias | string | Required. Name that subsequent nodes within the data processing engine use to the transform node. |
| dataType | BatchCalcJobDataType (enumeration of type string) | Required. Data type of the formula. Valid values are:
|
| decimalPlaces | integer | Number of digits to the right of a decimal point in the value. Required for the Numeric data type. |
| expression | string | Required. Formula defined by the user. |
| length | integer | Total length of the value including the decimal places. Required for data types: Text and Numeric. |
Represents a collection of fields that are used to sort the partitioned data.
Fields
| Field Name | Field Type | Description |
|---|---|---|
| name | string | Required. Name of the field that is used to sort data. |
| orderType | BatchCalcJobOrderType(enumeration of type string) | Order in which the data is sorted. Valid values are:
|
Represents a collection of fields relating to the union of data from two nodes in a data processing engine.
Fields
| Field Name | Field Type | Description |
|---|---|---|
| description | string | Description of the batch calculation job union. |
| isDisjointedSchema | boolean | Indicates whether the union is of two disjointed datasets. Set to True to allow joining of two datasets having no common fields. |
| label | string | Required. Label of the batch calculation job union. |
| name | string | Required. Name of the batch calculation job union. |
| sources | string[] | Names of the source nodes. |
Represents a collection of fields relating to the object in which the results of the data processing engine are written back.
Fields
| Field Name | Field Type | Description |
|---|---|---|
| description | string | Descriptions of the batch calculation job writeback object. |
| fields | BatchCalcJobWritebackMapping[] | Collection of the writeback fields. |
| isChangedRow | boolean | Indicates whether a row in the write back object is changed. Set to True to write back the changed rows. |
| label | string | Required. Name of the write back object. |
| name | string | Required. Name of the batch calculation job write back object. |
| operationType | BatchCalcJobWritebackOpn (enumeration of type string) | Required. Type of operation specified. Valid values are:
|
| sourceName | string | Required. Name of the source node associated with the write back object. |
| targetObjectName | string | Required. Object that is inserted or upserted by the data processing engine. |
| writebackSequence | integer | Sequence in which the target object is updated by the data processing engine. |
| writebackUser | string | ID of the user whose permissions decide which objects and fields of the target object can be updated. |
Represents a collection of fields relating to the mapping between results and the fields in the target object.
Fields
| Field Name | Field Type | Description |
|---|---|---|
| parentName | string | Name of the lookup object. Required only when the relationshipName field is defined. |
| relationshipName | string | Name of the lookup relationship. |
| sourceFieldName | string | Required. Name of the field in the source node that is written back. |
| targetFieldName | string | Required. Name of the sObject field to which the results are written back. |
Declarative Metadata Sample Definition
The following is an example of a BatchCalcJobDefinition component.
1<?xml version="1.0" encoding="UTF-8"?>
2<BatchCalcJobDefinition xmlns="http://soap.sforce.com/2006/04/metadata">
3 <aggregates>
4 <description>Aggregate Description</description>
5 <fields>
6 <aggregateFunction>Count</aggregateFunction>
7 <alias>NameCount</alias>
8 <sourceFieldName>Name</sourceFieldName>
9 </fields>
10 <groupBy>ContactId</groupBy>
11 <groupBy>Name</groupBy>
12 <label>AggregateOpportunities</label>
13 <name>AggregateOpportunities</name>
14 <sourceName>Opportunity</sourceName>
15 </aggregates>
16 <appends>
17 <description>Append desc</description>
18 <isDisjointedSchema>true</isDisjointedSchema>
19 <label>AppendAllAccounts</label>
20 <name>AppendAllAccounts</name>
21 <sources>AccountsOfManufacturingIndustry</sources>
22 <sources>MediaIndustry</sources>
23 </appends>
24 <datasources>
25 <description>Desc Contact</description>
26 <fields>
27 <alias>Id</alias>
28 <name>Id</name>
29 </fields>
30 <fields>
31 <alias>LastName</alias>
32 <name>LastName</name>
33 </fields>
34 <label>Contact</label>
35 <name>Contact</name>
36 <sourceName>Contact</sourceName>
37 <type>StandardObject</type>
38 </datasources>
39 <datasources>
40 <fields>
41 <alias>Name</alias>
42 <name>Name</name>
43 </fields>
44 <fields>
45 <alias>ContactId</alias>
46 <name>ContactId</name>
47 </fields>
48 <label>Opportunity</label>
49 <name>Opportunity</name>
50 <sourceName>Opportunity</sourceName>
51 <type>StandardObject</type>
52 </datasources>
53 <description>Calculates and creates transaction journal records based on the orders placed by the loyalty program members. The transaction journals are used to accrue points to the member.</description>
54 <filters>
55 <criteria>
56 <operator>Equals</operator>
57 <sequence>1</sequence>
58 <sourceFieldName>LastName</sourceFieldName>
59 <value>Salesforce</value>
60 </criteria>
61 <description>Filter Desc</description>
62 <filterCondition>1</filterCondition>
63 <isDynamicFilter>false</isDynamicFilter>
64 <label>AccountsOfManufacturingIndustry</label>
65 <name>AccountsOfManufacturingIndustry</name>
66 <sourceName>AccountOpportunities</sourceName>
67 </filters>
68 <hierarchyPaths>
69 <description>Hierarchy Path Node</description>
70 <hierarchyFieldName>Hierarchy_Path</hierarchyFieldName>
71 <isSelfFieldValueIncluded>true</isSelfFieldValueIncluded>
72 <label>Get Hierarchy</label>
73 <name>Get_Hierarchy</name>
74 <parentFieldName>ContactId</parentFieldName>
75 <selfFieldName>LastName</selfFieldName>
76 <sourceName>AppendAllAccounts</sourceName>
77 </hierarchyPaths>
78 <isTemplate>false</isTemplate>
79 <joins>
80 <description>Left Outer Join</description>
81 <fields>
82 <alias>ContactId</alias>
83 <sourceFieldName>Id</sourceFieldName>
84 <sourceName>Contact</sourceName>
85 </fields>
86 <fields>
87 <alias>LastName</alias>
88 <sourceFieldName>LastName</sourceFieldName>
89 <sourceName>Contact</sourceName>
90 </fields>
91 <fields>
92 <alias>NameCount</alias>
93 <sourceFieldName>NameCount</sourceFieldName>
94 <sourceName>AggregateOpportunities</sourceName>
95 </fields>
96 <fields>
97 <alias>OpportunityName</alias>
98 <sourceFieldName>Name</sourceFieldName>
99 <sourceName>AggregateOpportunities</sourceName>
100 </fields>
101 <joinKeys>
102 <primarySourceFieldName>Id</primarySourceFieldName>
103 <secondarySourceFieldName>ContactId</secondarySourceFieldName>
104 </joinKeys>
105 <label>AccountOpportunities</label>
106 <name>AccountOpportunities</name>
107 <primarySourceName>Contact</primarySourceName>
108 <secondarySourceName>AggregateOpportunities</secondarySourceName>
109 <type>LeftOuter</type>
110 </joins>
111 <label>Create Transaction Journals Based on Orders</label>
112 <parameters>
113 <dataType>Date</dataType>
114 <defaultValue>2020-01-01</defaultValue>
115 <description>Desc TextParameter</description>
116 <isMultiValue>false</isMultiValue>
117 <label>DateParameter</label>
118 <name>DateParameter</name>
119 </parameters>
120 <parameters>
121 <dataType>Filter</dataType>
122 <defaultValue>{"filterCondition": "1 AND 2", "criteria": [{"sourceFieldName": "NameCount","operator": "GreaterThan","value": "20","sequence": "1"}, {"sourceFieldName": "Name","operator": "Equals","value": "Salesforce","sequence": "2"}]}</defaultValue>
123 <isMultiValue>false</isMultiValue>
124 <label>FilterParameter</label>
125 <name>FilterParameter</name>
126 </parameters>
127 <parameters>
128 <dataType>Numeric</dataType>
129 <defaultValue>5000</defaultValue>
130 <description>Desc TextParameter</description>
131 <isMultiValue>false</isMultiValue>
132 <label>NumericParameter</label>
133 <name>NumericParameter</name>
134 </parameters>
135 <parameters>
136 <dataType>Text</dataType>
137 <defaultValue>@salesforce.com</defaultValue>
138 <description>Desc TextParameter</description>
139 <isMultiValue>false</isMultiValue>
140 <label>TextParameter</label>
141 <name>TextParameter</name>
142 </parameters>
143 <processType>DataProcessingEngine</processType>
144 <status>Inactive</status>
145 <transforms>
146 <description>transforms Desc</description>
147 <expressionFields>
148 <alias>NewLastName</alias>
149 <dataType>Text</dataType>
150 <expression>{LastName} + {$TextParameter}</expression>
151 <length>80</length>
152 </expressionFields>
153 <label>ManufacturingIndustry</label>
154 <name>ManufacturingIndustry</name>
155 <sourceName>AccountsOfManufacturingIndustry</sourceName>
156 <transformationType>Expression</transformationType>
157 </transforms>
158 <transforms>
159 <droppedFields>
160 <sourceFieldName>NewLastName</sourceFieldName>
161 </droppedFields>
162 <label>MediaIndustry</label>
163 <name>MediaIndustry</name>
164 <sourceName>ManufacturingIndustry</sourceName>
165 <transformationType>Slice</transformationType>
166 </transforms>
167 <transforms>
168 <description>compute relative transforms Desc</description>
169 <expressionFields>
170 <alias>NewLastName</alias>
171 <dataType>Text</dataType>
172 <expression>rank()</expression>
173 <length>80</length>
174 </expressionFields>
175 <label>ComputeRelativeManufacturingIndustry</label>
176 <name>ComputeRelativeManufacturingIndustry</name>
177 <orderBy>
178 <name>LastName</name>
179 <orderType>Ascending</orderType>
180 </orderBy>
181 <partitionBy>LastName</partitionBy>
182 <sourceName>MediaIndustry</sourceName>
183 <transformationType>ComputeRelative</transformationType>
184 </transforms>
185 <writebacks>
186 <fields>
187 <sourceFieldName>LastName</sourceFieldName>
188 <targetFieldName>LastName</targetFieldName>
189 </fields>
190 <isChangedRow>false</isChangedRow>
191 <label>exportToContact</label>
192 <name>exportToContact</name>
193 <description>Export To Contact</description>
194 <operationType>Insert</operationType>
195 <sourceName>AppendAllAccounts</sourceName>
196 <targetObjectName>Contact</targetObjectName>
197 <writebackSequence>1</writebackSequence>
198 </writebacks>
199</BatchCalcJobDefinition>The following is an example package.xml that references the previous definition.
1<?xml version="1.0" encoding="UTF-8"?>
2<!--
3 ~ Copyright 2020 salesforce.com, inc.
4 ~ All Rights Reserved
5 ~ Company Confidential
6-->
7<Package xmlns="http://soap.sforce.com/2006/04/metadata">
8 <types>
9 <members>*</members>
10 <name>BatchCalcJobDefinition</name>
11 </types>
12 <version>[ftest]</version>
13</Package>Wildcard Support in the Manifest File
This metadata type supports the wildcard character * (asterisk) in the package.xml manifest file. For information about using the manifest file, see Deploying and Retrieving Metadata with the Zip File.