Zynk Workflow Documentation

This task will update or insert multiple records in Salesforce. Existing records are matched with those provided in the input file, based on the Salesforce field specified in the Salesforce Key Field setting, and the field from the input file specified by the XML Key Field setting. Unlike the Importing Records to Salesforce and Bulk Salesforce Operation task, the Salesforce field does not need to be of type External Id. If a match is found the existing record will be updated, or if no match is found a new record will be inserted.



The Salesforce (Bulk) connection to use, see Connecting to Salesforce (Bulk)

Salesforce Key Field

The field in Salesforce to use to match existing records.

Salesforce Object

The record type to upload e.g. Account.

Input File

The file containing the raw product data to import to Salesforce. The contents of this file will be transformed using the XSLT file provided before being imported to Salesforce.

XML Key Field

The relative XPath query to get the value to match on from a record in the input file.

XPath Query

The XPath query (relative to the one provided in the XPath Query setting) to get individual records from the input file.


The XSLT file to use to transform the input file to objects in the Salesforce XML format. The XML field names outputted from the XSLT must match Salesforce object API field names. A list of standard API field names can be found here. Any custom fields added to the chosen object are supported, and are usually named like Account_Ref__c.

Zynk Settings

See Common Task Settings


You can find an example of how to use this task in the Salesforce to Sage 50 Integration article.

Sample input file containing customers in the Zynk XML format, to be uploaded to Salesforce as accounts:

<?xml version="1.0"?>
      <CompanyName>ABS Garages Ltd</CompanyName>
        <Company>ABS Garages Ltd</Company>
        <Address1>Unit 34</Address1>
        <Address2>Holystone Ind Estate</Address2>
        <Postcode>NE31 1VB</Postcode>
        <County>Tyne &amp; Wear</County>
        <Telephone>0191 254 5909</Telephone>
        <Fax>0191 254 5907</Fax>

Given this input file, the XPath Query setting would need to be set to Company/Customers/Customer, the XML Key Field would be set to AccountReference and the Salesforce Object would be set to Account. The Salesforce Key Field setting would be set to AccountNumber, as this is the field which will be used when searching for existing accounts in Salesforce.

Sample XSLT file to convert the input file above to the Salesforce XML format:

<?xml version="1.0" encoding="utf-8"?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
  <xsl:output method="xml" version="1.0" encoding="utf-8" indent="yes" xmlns="http://www.force.com/2009/06/asyncapi/dataload"/>
  <xsl:template match="/">
    <sObjects xmlns="http://www.force.com/2009/06/asyncapi/dataload">
      <xsl:for-each select="Company/Customers/Customer">
          <!-- The task will write out the Id field when the record already exists in Salesforce, this just needs to be copied by the XSLT -->
          <xsl:if test="Id"> 
            <Id><xsl:value-of select="Id"/></Id>
            <xsl:value-of select="AccountReference"/>
            <xsl:value-of select="Currency" />
            <xsl:value-of select="CompanyName" />
            <xsl:value-of select="CustomerInvoiceAddress/Address1"/>
            <xsl:text> </xsl:text>
            <xsl:value-of select="CustomerInvoiceAddress/Address2"/>
            <xsl:value-of select="CustomerInvoiceAddress/Town" />
            <xsl:value-of select="CustomerInvoiceAddress/County" />
            <xsl:value-of select="CustomerInvoiceAddress/Postcode" />
            <xsl:value-of select="CustomerInvoiceAddress/Country" />
            <xsl:value-of select="CustomerInvoiceAddress/Telephone" />
            <xsl:value-of select="CustomerInvoiceAddress/Fax" />
            <xsl:value-of select="CustomerInvoiceAddress/Website" />

Back | Edit on Github