SF_UseAssignmentRuleId
SF_UseAssignmentRuleId
Usage
SF_UseAssignmentRuleId
allows you to pass an AssignmentRuleID that specifies the owner of a Case or Lead. You can only use it to pass an AssignmentRuleID if the data is being pushed to either the Case or Lead objects.
Query the AssignmentRule table to obtain the AssignmentRuleID that is to be used to specify the owner of the Case or Lead objects:
SELECT * FROM SALESFORCE_LS.CData.Salesforce.AssignmentRule
where SALESFORCE_LS is the name of your linked server.
The AssignmentRuleID is passed as the 4th parameter in the SF_UseAssignmentRuleId command. Make sure to examine the Error column in the Result table after running the command to look for possible errors.
Syntax
EXEC SF_UseAssignmentRuleId operation, 𝘭𝘪𝘯𝘬𝘦𝘥_𝘴𝘦𝘳𝘷𝘦𝘳, load_SQL_Table, assignment_rule_id, options
where
-
operation—must be
Insert
orUpdate
-
linked_server—the linked server name
-
load_SQL_Table—must be the Case or Lead input table
-
assignment_rule_id—the AssignmentRuleId value from the AssignmentRule table
-
options—valid options for
SF_UseAssignmentRuleId
Basic Examples
Exec SF_UseAssignmentRuleId 'Insert', 'SALESFORCE', 'Case_Insert', '01Q4S000000EIWEUA4'
Exec SF_UseAssignmentRuleId 'Update', 'SALESFORCE', 'Lead_Update', '01Q4S000000EIWEUA4', 'ignorefailures(50)'
NOTE: the BulkAPI is case-sensitive with respect to the AssignmentRuleID value; use the exact AssignmentRuleID given in the AssignmentRule table.