﻿<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0">
  <channel>
    <title>Team Blog</title>
    <link>http://www.simego.com/blog</link>
    <description>Blog articles from the Simego team relating to Simego products and other software technology</description>
    <item>
      <link>http://www.simego.com/blog/updating-active-directory-manager-attribute</link>
      <author>info@simego.com (Rebecca Allen)</author>
      <title>Updating the Active Directory Manager Attribute</title>
      <description>&lt;p&gt;The Active Directory connector has built in columns that handle all the hard work when mapping to attributes that need to lookup values, these are the Data Sync columns (&lt;code&gt;DS-&lt;/code&gt;) that will only show in Data Sync.&lt;/p&gt;
&lt;p&gt;When updating or adding a manager attribute to a user in Active Directory you need to lookup the manager within your OU by providing the distinguished name. With the Data Sync columns you can choose to use either their Email, their Employee ID, their SAMAccountName or the Distinguished Name.
Data Sync will then lookup the value in the OU you are connected to and return the DN, this is what AD requires internally when writing to the manager attribute.&lt;/p&gt;
&lt;div class="text-center"&gt;&lt;img src="https://images.simego.com/blog/activedirectory-manager.png" title="Active Directory - Manager Update" alt="Active Directory - Manager Update"/&gt;
&lt;/div&gt;
&lt;p&gt;The following page discusses how you would go about configuring your project to update the manager attribute in Active Directory for existing users, and then the options you have to automate and schedule your project.
We cover how to add the manager attribute to new users in the &lt;a href="/blog/create-new-active-directory-users"&gt;Creating AD Users blog&lt;/a&gt;.&lt;/p&gt;
&lt;section class="section-tiny alternate-color"&gt;
&lt;div class="container"&gt;
&lt;h3&gt;Contents&lt;/h3&gt;
&lt;ol&gt;
                    &lt;li&gt;
                        &lt;a href="#requirements"&gt;Requirements&lt;/a&gt;
                    &lt;/li&gt;
                    &lt;li&gt;
                        &lt;a href="#connect"&gt;Connect to your Source and Active Directory&lt;/a&gt;
                    &lt;/li&gt;
                   &lt;li&gt;
                        &lt;a href="#connect"&gt;Connect to Active Directory&lt;/a&gt;
                    &lt;/li&gt;
                    &lt;li&gt;
                        &lt;a href="#mapping"&gt;Schema Mapping&lt;/a&gt;
                    &lt;/li&gt;
                    &lt;li&gt;
                        &lt;a href="#sync"&gt;Preview the Compare Results and Sync&lt;/a&gt;
                    &lt;/li&gt;
                    &lt;li&gt;
                        &lt;a href="#misc"&gt;Miscellaneous&lt;/h2&gt;
                    &lt;/li&gt;
                    &lt;ul&gt;                       
                        &lt;li&gt;
                            &lt;a href="#attribute"&gt;Adding Additional Attributes&lt;/a&gt;
                        &lt;/li&gt;                        
                    &lt;/ul&gt;
                    &lt;li&gt;
                        &lt;a href="#automate"&gt;Automate &amp;amp; Schedule&lt;/a&gt;
                    &lt;/li&gt;
                &lt;/ol&gt;
&lt;/div&gt;
&lt;/section&gt;
&lt;h2 id="requirements"&gt;Requirements&lt;/h2&gt;
&lt;p&gt;Before getting started you need to ensure you have the following:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Windows 10 or Windows Server&lt;/li&gt;
&lt;li&gt;Downloaded &amp;amp; Installed Data Synchronisation Studio&lt;/li&gt;
&lt;li&gt;Have a source data set containing your user and manager details&lt;/li&gt;
&lt;li&gt;Have access to Active Directory&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;If you do not have &lt;strong&gt;Data Synchronisation Studio&lt;/strong&gt; you can get a &lt;a href="/install/data-synchronisation-studio"&gt;free evaluation edition&lt;/a&gt;. To test the automation using Ouvvi please contact us to upgrade your trial key.&lt;/p&gt;
&lt;h2 id="connect"&gt;Connect to your Source and Active Directory&lt;/h2&gt;
&lt;p&gt;Start by opening Data Sync and connect to your source data. This can be a SQL table, excel spreadsheet or a CSV as a few examples. For this scenario we will be using a SQl table, but the process will be the same for any of our available connectors.&lt;/p&gt;
&lt;p&gt;You then need to connect to your Active Directory users.
To do this click onto &lt;strong&gt;Connect Datasource&lt;/strong&gt; in the target window and go to &lt;strong&gt;Active Directory&lt;/strong&gt; &amp;gt; &lt;strong&gt;Active Directory V2 - Users/Contacts/Groups/Computers&lt;/strong&gt;.&lt;/p&gt;
&lt;p&gt;By default &lt;strong&gt;Users&lt;/strong&gt; will be selected from the DefaultAttributes drop-down menu, this is what you need so you don't need to change this. Then enter in the LDAP path to your Active Directory instance, and enter in any credentials you need to access AD.&lt;/p&gt;
&lt;p&gt;The LDAP Path can be just your server name or the path (including the server name) to a specific OU. For example connecting with just a Server Name would look like this: &lt;code&gt;LDAP://dc01&lt;/code&gt;, and connecting to a specific OU would look similar to: &lt;code&gt;LDAP://dc01/OU=Demo,DC=lab,DC-simego,DC=com&lt;/code&gt;.
You can find more details on how to find your LDAP path &lt;a href="/docs/data-sync/connectors/ad/ldap"&gt;here&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/ad-users-connection.png" alt="AD Connection Details" title="AD Connection Details" /&gt;&lt;/p&gt;
&lt;p&gt;You can then click &lt;strong&gt;Connect &amp;amp; Create Library Connection&lt;/strong&gt; to save the connection to the connection library. Just enter in a name for the connection and click OK. Then refresh the connection window and your Active Directory connection will be visible in the list.&lt;/p&gt;
&lt;p&gt;This only needs to be done once per OU as you will be able to access other objects such as Users and Contacts from the connection window.&lt;/p&gt;
&lt;p&gt;If you have already saved your connection to AD you can select the Users object from your AD connection.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/ad-users-connectionlibrary.png" alt="Connection Library - Active Directory Users" title="Connection Library - Active Directory Users" /&gt;&lt;/p&gt;
&lt;h2 id="mapping"&gt;Mapping&lt;/h2&gt;
&lt;p&gt;We then need to map the source columns to their corresponding attributes in AD.&lt;/p&gt;
&lt;p&gt;For the manager attribute you need to have listed either the email address, employee ID, SAMAccount name or distinguished name of the manager in your source data.&lt;/p&gt;
&lt;p&gt;Map this source column to the corresponding DS- column from the target window.
For example we are using the manager's email address, so this is mapped to the &lt;strong&gt;DS-Manager-Email&lt;/strong&gt; column.
Data Sync will then do the lookup for you and return the DN of the manager when writing to AD.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/ad-manager-update-mapping.png" alt="Mapping Manager Attribute" title="Mapping Manager Attribute" /&gt;&lt;/p&gt;
&lt;h2 id="sync"&gt;Preview the Compare Results and Sync&lt;/h2&gt;
&lt;p&gt;Once the mapping is configured you can compare the source data against the target and preview the results.&lt;/p&gt;
&lt;p&gt;In this example we can see we have 5 updates to make, and the changes to be applied to Active Directory are highlighted in yellow.&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;Please note deletes are disabled by default but will still show in the results if records are not present in the source but are in the target.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/ad-manager-update-compareresults.png" alt="Compare Results" title="Compare Results" /&gt;&lt;/p&gt;
&lt;p&gt;To apply these changes click onto Synchronise and then Start to begin the sync.&lt;/p&gt;
&lt;p&gt;Your Active Directory users will now have the manager attribute updated with the value you supplied.
Make sure to save your project so that you can use it again in the future.&lt;/p&gt;
&lt;h2 id="automate"&gt;Automate &amp;amp; Schedule&lt;/h2&gt;
&lt;p&gt;You may want to automate the manager update project so that it runs on a regular basis so that your Active Directory is always kept up to date.
To do this you can use either the Run Tool or Ouvvi.&lt;/p&gt;
&lt;p&gt;Ouvvi gives more options for scheduling, with both time and event based triggers. So you could configure a trigger to start your project whenever a change is detected in your SQL table or SharePoint List. Note that this requires using a modified date time stamp in your SQL table.&lt;/p&gt;
&lt;p&gt;Alternatively you can use the run tool to schedule the project to run using Windows Task Scheduler.&lt;/p&gt;
&lt;h3 id="run-via-the-run-tool"&gt;Run via the Run Tool&lt;/h3&gt;
&lt;p&gt;The Run Tool is an additional program that comes linked to Data Sync and enables you to build out your data integration jobs.&lt;/p&gt;
&lt;p&gt;You can use this to group Data Sync projects that need to run in order and add additional step types such as adding an status report to email you when the project has run and if there were any failures. Each step is run in the order it appears in the list and you can apply conditional rules so that the next step can run if the previous one succeeded or had data changes for example.
To find out more please see our &lt;a href="/docs/data-sync/run-tool/intro"&gt;Run Tool Documentation&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;To open your project in the Run Tool, in your Data Sync project go to &lt;strong&gt;Tools&lt;/strong&gt; &amp;gt;&lt;strong&gt;Open in Run Tool&lt;/strong&gt;.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/ad-managerupdate-tools.png" alt="Open in Run Tool" title="Open in Run Tool" /&gt;&lt;/p&gt;
&lt;p&gt;You can then click onto the green &lt;strong&gt;Run&lt;/strong&gt; button to check it runs as expected. If there are data changes you will be provided with a count of how many items were added updated or deleted&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/ad-managerupdate-runtool.png" alt="Run Tool" title="Run Tool" /&gt;&lt;/p&gt;
&lt;h3 id="run-via-the-command-line"&gt;Run via the Command Line&lt;/h3&gt;
&lt;p&gt;Another option is to Run the Run Tool project or single Data Sync project from the command line. To do this pass the path to the project file like this:&lt;/p&gt;
&lt;h4 id="run-tool-project"&gt;Run Tool Project&lt;/h4&gt;
&lt;div class="lang-cmd editor-colors"&gt;%DATASYNCINSTALLPATH%\Simego.DataSync.Run.exe -execute "D:\DSProjects\myproject.dsrun"
&lt;/div&gt;
&lt;h4 id="data-sync-project"&gt;Data Sync Project&lt;/h4&gt;
&lt;div class="lang-cmd editor-colors"&gt;%DATASYNCINSTALLPATH%\Simego.DataSync.Run.exe -execute "D:\DSProjects\myproject.dsprj"
&lt;/div&gt;
&lt;h3 id="automate-with-windows-task-scheduler"&gt;Automate with Windows Task Scheduler&lt;/h3&gt;
&lt;p&gt;You can then schedule your Run Tool project to run when you need it to using Windows Task Scheduler. For the full details on how to do this see our &lt;a href="/docs/data-sync/run-tool/schedule-taskscheduler"&gt;Task Scheduler Documentation&lt;/a&gt;.&lt;/p&gt;
&lt;h3 id="automate-with-ouvvi"&gt;Automate with Ouvvi&lt;/h3&gt;
&lt;p&gt;An alternative option, with more scheduling capabilities is to use &lt;a href="/products/ouvvi-console"&gt;Ouvvi Automation Server&lt;/a&gt;. Ouvvi enables you to fully schedule and manage all of your Data Integration Projects, from Data Sync projects to SQL Statements to Powershell Scripts.&lt;/p&gt;
&lt;p&gt;It provides full logging and documentation capabilities to fully manage your integration operations.&lt;/p&gt;
&lt;p&gt;To find out more see our &lt;a href="/docs/ouvvi/userguide/intro"&gt;Ouvvi Documentation&lt;/a&gt; or send us an email.&lt;/p&gt;
&lt;p&gt;&lt;img src="http://www.simego.com/content/img/ouvvi-dashboard-example.png" alt="Ouvvi Automation Server" title="Ouvvi Automation Server" /&gt;&lt;/p&gt;
&lt;p&gt;To learn about creating new Active Directory Users, setting default passwords and adding them to groups you can see our &lt;a href="/blog/create-new-active-directory-users"&gt;Create AD Users blog&lt;/a&gt;.&lt;/p&gt;
</description>
      <source url="http://www.simego.com/blog">Team Blog</source>
      <pubDate>Fri, 18 Feb 2022 08:49:45 +0000</pubDate>
    </item>
    <item>
      <link>http://www.simego.com/blog/create-new-active-directory-users</link>
      <author>info@simego.com (Rebecca Allen)</author>
      <title>Creating New Active Directory Users</title>
      <description>&lt;p&gt;If you have a series of users to provision in your Active Directory then you can make the process simple and automated using Data Sync and Ouvvi.&lt;/p&gt;
&lt;p&gt;The following page will cover how to configure a Data Sync project to create Active Directory user accounts, set the manager, assign the users to groups and set a default password in the same project.
We then cover a few options you have in order to automate the project so that it can be run automatically.&lt;/p&gt;
&lt;p&gt;You can create Active Directory users from any data source, for example a CSV, Excel Spreadsheet, SQL Table or a SharePoint list to list a few.&lt;/p&gt;
&lt;div class="text-center"&gt;&lt;img src="https://images.simego.com/blog/activedirectory-add-users.png" title="Create AD Users" alt="Create AD Users"/&gt;
&lt;/div&gt;
&lt;section class="section-tiny alternate-color"&gt;
&lt;div class="container"&gt;
&lt;h3&gt;Contents&lt;/h3&gt;
&lt;ol&gt;
                    &lt;li&gt;
                        &lt;a href="#requirements"&gt;Requirements&lt;/a&gt;
                    &lt;/li&gt;
                    &lt;li&gt;
                        &lt;a href="#connect"&gt;Connect to your Source&lt;/a&gt;
                    &lt;/li&gt;
                    &lt;li&gt;
                        &lt;a href="#activedirectory"&gt;Connect to Active Directory&lt;/a&gt;
                    &lt;/li&gt;
                   &lt;li&gt;
                        &lt;a href="#mapping"&gt;Map the Source &amp;amp; Target Columns&lt;/a&gt;
                    &lt;/li&gt;
                    &lt;ul&gt;
                        &lt;li&gt;
                            &lt;a href="#password"&gt;Set a Default Password&lt;/a&gt;
                        &lt;/li&gt;
                        &lt;li&gt;
                            &lt;a href="#manager"&gt;Assign a Manager&lt;/a&gt;
                        &lt;/li&gt;
                        &lt;li&gt;
                            &lt;a href="#enable"&gt;Enable User Accounts&lt;/a&gt;
                        &lt;/li&gt;
                        &lt;li&gt;
                            &lt;a href="#groups"&gt;Add to Groups&lt;/a&gt;
                        &lt;/li&gt;
                    &lt;/ul&gt;
                    &lt;li&gt;
                        &lt;a href="#preview"&gt;Preview and Sync the Results&lt;/a&gt;
                    &lt;/li&gt;
                    &lt;li&gt;
                        &lt;a href="#automate"&gt;Automate &amp;amp; Schedule&lt;/a&gt;
                    &lt;/li&gt;
                    &lt;li&gt;
                        &lt;a href="#video"&gt;Video - Adding Users&lt;/a&gt;
                    &lt;/li&gt;
                &lt;/ol&gt;
&lt;/div&gt;
&lt;/section&gt;
&lt;h2 id="requirements"&gt;Requirements&lt;/h2&gt;
&lt;p&gt;Before getting started you need to ensure you have the following:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Windows 10 or Windows Server&lt;/li&gt;
&lt;li&gt;Downloaded &amp;amp; Installed Data Synchronisation Studio&lt;/li&gt;
&lt;li&gt;A data set with your user details listed&lt;/li&gt;
&lt;li&gt;Access to Active Directory&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;If you do not have &lt;strong&gt;Data Synchronisation Studio&lt;/strong&gt; you can get a &lt;a href="/install/data-synchronisation-studio"&gt;free evaluation edition&lt;/a&gt;.
To test the automation using Ouvvi please contact us to upgrade your trial key.&lt;/p&gt;
&lt;h2 id="connect"&gt;Connect to your Source&lt;/h2&gt;
&lt;p&gt;First you need to prepare your source data to make sure you have all the data you want to add. You want your source data to look like you want your Active Directory to be.&lt;/p&gt;
&lt;p&gt;If you want to add a manager you need to ensure you have either a manager email, employee ID, distinguished name, or sAMAccountName listed against your users. In this example we have the manager email address.&lt;/p&gt;
&lt;p&gt;If you want to add the users to groups then you need to ensure the groups are listed with a semi colon separating them. The dataset shown below has users added to three different groups and these are listed as: &lt;code&gt;Group A;Group B;Group C&lt;/code&gt;&lt;/p&gt;
&lt;p&gt;A preview of the dataset being used in this example can be seen below:&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/ad-new-users-dataset.png" alt="Data Set" title="Data Set" /&gt;&lt;/p&gt;
&lt;p&gt;Once you have your data together connect to this as your source in the Data Sync Project by clicking into the data source A window.  In this example our data is stored in a SQL Table, but you can use any of the built in providers to connect to your source data.&lt;/p&gt;
&lt;h2 id="activedirectory"&gt;Connect to Active Directory&lt;/h2&gt;
&lt;p&gt;You now need to connect the target data source to your Active Directory OU.
To do this click onto &lt;strong&gt;Connect Datasource&lt;/strong&gt; in the target window and go to &lt;strong&gt;Active Directory&lt;/strong&gt; &amp;gt; &lt;strong&gt;Active Directory V2 - Users/Contacts/Groups/Computers&lt;/strong&gt;.&lt;/p&gt;
&lt;p&gt;By default &lt;strong&gt;Users&lt;/strong&gt; will be selected from the DefaultAttributes drop-down menu, this is what you need so you don't need to change this. Then enter in the LDAP path to your Active Directory instance, and enter in any credentials you need to access AD.&lt;/p&gt;
&lt;p&gt;You can enter in the full LDAP path (including the server name) or just the server name.
If you just use the server name your path would look similar to: &lt;code&gt;LDAP://dc01&lt;/code&gt;.&lt;br /&gt;
Otherwise an example path connecting to a specific OU could be: &lt;code&gt;LDAP://dc01/OU=Test,DC=demo,DC=simego,DC=com&lt;/code&gt;.
We have more details on finding the LDAP Path in our &lt;a href="/docs/data-sync/connectors/ad/ldap"&gt;documentation&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/ad-users-connection.png" alt="AD Connection Details" title="AD Connection Details" /&gt;&lt;/p&gt;
&lt;p&gt;Then click &lt;strong&gt;Connect &amp;amp; Create Library Connection&lt;/strong&gt; to save the connection to the connection library. Just enter in a name for the connection and click OK. Then refresh the connection window and your Active Directory connection will be visible in the list.&lt;/p&gt;
&lt;p&gt;This only needs to be done once per OU as you will be able to access other objects such as Groups and Contacts from the connection window.&lt;/p&gt;
&lt;p&gt;If you have already saved your connection to AD you can select the Users object from your AD connection.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/ad-users-connectionlibrary.png" alt="Connection Library - Active Directory Users" title="Connection Library - Active Directory Users" /&gt;&lt;/p&gt;
&lt;h2 id="mapping"&gt;Map the Source &amp;amp; Target Columns&lt;/h2&gt;
&lt;p&gt;The next step is to configure the schema map so that your source columns are linked to the correct attribute in Active Directory.&lt;/p&gt;
&lt;p&gt;You need to specify a key column to identify each user as unique.
We find that the AccountName is a good field for this so map this to the &lt;code&gt;DS-SAMAccountName&lt;/code&gt; column another alternative is LogonName (&lt;code&gt;DS-UserPrincipalName&lt;/code&gt;).&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;&lt;code&gt;DS-&lt;/code&gt; columns are Data Sync attribute columns that handle the addition of that field for each user. These usually have to be handled differently to add the values, which in previous versions would have needed you to write code. These columns take away the need to add code to project automation.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;Your basic schema map might look similar to the screen capture below:&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/ad-addusers-user-mapping.png" alt="User Details Schema" title="User Details Schema" /&gt;&lt;/p&gt;
&lt;p&gt;You can then follow each of the sections below to &lt;a href="#manager"&gt;add the manager details&lt;/a&gt;, &lt;a href="#password"&gt;set a password&lt;/a&gt;, &lt;a href="#enable"&gt;enable the user account&lt;/a&gt; and &lt;a href="#groups"&gt;add the user to groups&lt;/a&gt;.&lt;/p&gt;
&lt;h3 id="password"&gt;Set the Default Password&lt;/h3&gt;
&lt;p&gt;To set a password you need to map the password column from your source to the &lt;code&gt;DS-SetPassword&lt;/code&gt; column in the target.&lt;/p&gt;
&lt;p&gt;If you don't have a password listed in your source data you can supply a password, such as &lt;code&gt;!Password123&lt;/code&gt;, to be used to all new accounts using calculated columns.&lt;/p&gt;
&lt;p&gt;To do this click onto the &lt;code&gt;fx&lt;/code&gt; button in the data source A toolbar to open the calculated column window.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/images/calculated-column-new.png" alt="Calculated Column Button" title="Calculated Column Button" /&gt;&lt;/p&gt;
&lt;p&gt;Your calculated column should then be configured to look similar to:&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/images/ad-addusers-passwordgenerate.png" alt="Password Calculated Column" title="Password Calculated Column" /&gt;&lt;/p&gt;
&lt;p&gt;Add your column to the schema map and match this to the &lt;code&gt;DS-SetPassword&lt;/code&gt; column in the target.&lt;/p&gt;
&lt;p&gt;To make the user have to change the password at their next logon, as the default is not secure, we need to set &lt;strong&gt;pwdlastset&lt;/strong&gt; in the target connection properties with the &lt;strong&gt;OnCreateChangePasswordNextLogon&lt;/strong&gt; property. By default this is set to &lt;strong&gt;true&lt;/strong&gt;, however if you do not want users to change the password then set this to false.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/images/ad-passwordchange.png" alt="PasswordLastSet" title="PasswordLastSet" /&gt;&lt;/p&gt;
&lt;p&gt;So then the password does not cause an update action each time the project runs (on existing user accounts) you need to change the schema property &lt;strong&gt;Ignore&lt;/strong&gt; for the Password column to &lt;strong&gt;True&lt;/strong&gt;.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/ad-addusers-password-schema.png" alt="Ignore Password Updates" title="Ignore Password Updates" /&gt;&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;NB. The password can only be set on new user accounts&lt;/p&gt;
&lt;/blockquote&gt;
&lt;h3 id="manager"&gt;Set the Manager Attribute&lt;/h3&gt;
&lt;p&gt;To set the manager attribute you just need to map one of the following columns to it's corresponding data sync column.&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Distinguished Name -&amp;gt; DS-Manager-DN&lt;/li&gt;
&lt;li&gt;EmployeeID -&amp;gt; DS-Manager-EmployeeID&lt;/li&gt;
&lt;li&gt;Email -&amp;gt; DS-Manager-Email&lt;/li&gt;
&lt;li&gt;sAMAccountName -&amp;gt; DS-Manager-SAMAccountName&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;In this example the manager is listed by the Email Address, so for this we would use the target column &lt;code&gt;DS-Manager-Email&lt;/code&gt;.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/ad-addusers-manager-mapping.png" alt="Manager Mapping" title="Manager Mapping" /&gt;&lt;/p&gt;
&lt;p&gt;Please note that if the manager does not exist in Active Directory it will return null for the manager field. For example a new manager may be in the list of users you are adding. If you have this scenario then you will need to run the project again to update the manager column. Make sure to set &lt;code&gt;EnableUpdate&lt;/code&gt; to &lt;code&gt;True&lt;/code&gt; if it is not already.&lt;/p&gt;
&lt;p&gt;For a more detailed description on updating the manager attribute for existing users please see our &lt;a href="/blog/updating-active-directory-manager-attribute"&gt;other blog here&lt;/a&gt;.&lt;/p&gt;
&lt;h3 id="enable"&gt;Enable User Accounts&lt;/h3&gt;
&lt;p&gt;You can also set the user account to be enabled or disabled by returning a boolean value.
Return &lt;strong&gt;True&lt;/strong&gt; to disable the account and &lt;strong&gt;False&lt;/strong&gt; to enable the account.&lt;/p&gt;
&lt;p&gt;Then map this column to &lt;code&gt;DS-UAC-Disabled&lt;/code&gt;.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/ad-addusers-diasbled-mapping.png" alt="Disabled Mapping" title="Disabled Mapping" /&gt;&lt;/p&gt;
&lt;h3 id="groups"&gt;Add to Groups&lt;/h3&gt;
&lt;p&gt;To add the users as members in groups you need to have the groups they are to be members of listed in an array separated by a semi colon. Your groups listed must already exist in Active Directory when adding users.
E.g. The source data in this example has a value of &lt;strong&gt;Group A;Group B;Group C&lt;/strong&gt; for the groups column.&lt;/p&gt;
&lt;p&gt;If your groups do not already exist checkout our &lt;a href="/docs/data-sync/connectors/ad/groups"&gt;groups documentation&lt;/a&gt; which covers how to create groups and manager the assigned users.&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;If your group does not exist in Active Directory then Data Sync will throw an error when you try to synchronise.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;To add the users to these groups, map your source &lt;strong&gt;Group&lt;/strong&gt; column to the target column &lt;code&gt;DS-User-MemberOf&lt;/code&gt; and Data Sync will handle the rest for you at the point on synchronisation.&lt;/p&gt;
&lt;p&gt;At the end of this your schema map should look something like the following image.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/ad-addusers-schemamap.png" alt="Add Users Final Schema Map" title="Add Users Final Schema Map" /&gt;&lt;/p&gt;
&lt;h2 id="preview"&gt;Preview and Sync the Results&lt;/h2&gt;
&lt;p&gt;To add the data to your Active Directory you need to click the &lt;code&gt;Compare A &amp;gt; B&lt;/code&gt; button. This will enable you to preview the additions or changes being made to your Active Directory.&lt;/p&gt;
&lt;p&gt;If it shows delete actions do not panic, these are disabled by default. If you want to enable deletes you will need to set &lt;code&gt;EnableDelete&lt;/code&gt; to &lt;code&gt;True&lt;/code&gt; on the target.&lt;/p&gt;
&lt;p&gt;In this example we have 9 users to add, clicking onto the Add line will show you the data that is to be added to Active Directory.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/ad-addusers-compareresults.png" alt="Preview Compare Results" title="Preview Compare Results" /&gt;&lt;/p&gt;
&lt;p&gt;If you want to run a test on one account rather than the whole dataset then deselect the check-boxes using the clear all button and then check the check-box against the record you want to add.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/ad-addusers-clearall-select.png" alt="Select a Record" title="Select a Record" /&gt;&lt;/p&gt;
&lt;p&gt;Now click the Synchronise button and then start to begin the sync to add your user accounts to Active Directory.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/ad-addusers-syncresults.png" alt="Sync Results" title="Sync Results" /&gt;&lt;/p&gt;
&lt;p&gt;To check the data has been synchronised successfully you can either browse your AD for a user account or you can click onto the Preview Datasource in the target window.&lt;/p&gt;
&lt;p&gt;You should now have all your users added to Active Directory with their managers assigned, them being members of the groups they need to be in, and have a password set so that they can log in.&lt;/p&gt;
&lt;h2 id="automate"&gt;Automate &amp;amp; Schedule&lt;/h2&gt;
&lt;p&gt;You may want to automate the creating of user records in active directory so that it runs on a regular basis, to do this you can use either the Run Tool or Ouvvi.&lt;/p&gt;
&lt;p&gt;Ouvvi gives more options for scheduling, with both time and event based triggers. So you could configure a trigger to start your project whenever a change is detected in your SQL table or SharePoint List. Note that this requires using a modified date time stamp in your SQL table.&lt;/p&gt;
&lt;p&gt;Alternatively you can use the Run Tool to schedule the project to run using Windows Task Scheduler.&lt;/p&gt;
&lt;h3 id="run-via-the-run-tool"&gt;Run via the Run Tool&lt;/h3&gt;
&lt;p&gt;The Run Tool is an additional program that comes linked to Data Sync and enables you to build out your data integration jobs.&lt;/p&gt;
&lt;p&gt;You can use this to group Data Sync projects that need to run in order and add additional step types such as adding an status report to email you when the project has run and if there were any failures. Each step is run in the order it appears in the list and you can apply conditional rules so that the next step can run if the previous one succeeded or had data changes for example.
To find out more please see our &lt;a href="/docs/data-sync/run-tool/intro"&gt;Run Tool Documentation&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;To open your project in the Run Tool, in your Data Sync project go to &lt;strong&gt;Tools&lt;/strong&gt; &amp;gt;&lt;strong&gt;Open in Run Tool&lt;/strong&gt;.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/ad-addusers-tools.png" alt="Open in Run Tool" title="Open in Run Tool" /&gt;&lt;/p&gt;
&lt;p&gt;You can then click onto the green &lt;strong&gt;Run&lt;/strong&gt; button to check it runs as expected. If there are data changes you will be provided with a count of how many items were added updated or deleted&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/ad-addusers-runtool.png" alt="Run Tool" title="Run Tool" /&gt;&lt;/p&gt;
&lt;h3 id="run-via-the-command-line"&gt;Run via the Command Line&lt;/h3&gt;
&lt;p&gt;Another option is to Run the Run Tool project or single Data Sync project from the command line. To do this pass the path to the project file like this:&lt;/p&gt;
&lt;h4 id="run-tool-project"&gt;Run Tool Project&lt;/h4&gt;
&lt;div class="lang-cmd editor-colors"&gt;%DATASYNCINSTALLPATH%\Simego.DataSync.Run.exe -execute "D:\DSProjects\myproject.dsrun"
&lt;/div&gt;
&lt;h4 id="data-sync-project"&gt;Data Sync Project&lt;/h4&gt;
&lt;div class="lang-cmd editor-colors"&gt;%DATASYNCINSTALLPATH%\Simego.DataSync.Run.exe -execute "D:\DSProjects\myproject.dsprj"
&lt;/div&gt;
&lt;h3 id="automate-with-windows-task-scheduler"&gt;Automate with Windows Task Scheduler&lt;/h3&gt;
&lt;p&gt;You can then schedule your Run Tool project to run when you need it to using Windows Task Scheduler. For the full details on how to do this see our &lt;a href="/docs/data-sync/run-tool/schedule-taskscheduler"&gt;Task Scheduler Documentation&lt;/a&gt;.&lt;/p&gt;
&lt;h3 id="automate-with-ouvvi"&gt;Automate with Ouvvi&lt;/h3&gt;
&lt;p&gt;An alternative option, with more scheduling capabilities is to use &lt;a href="/products/ouvvi-console"&gt;Ouvvi Automation Server&lt;/a&gt;. Ouvvi enables you to fully schedule and manage all of your Data Integration Projects, from Data Sync projects to SQL Statements to Powershell Scripts.&lt;/p&gt;
&lt;p&gt;It provides full logging and documentation capabilities to fully manage your integration operations.&lt;/p&gt;
&lt;p&gt;To find out more see our &lt;a href="/docs/ouvvi/userguide/intro"&gt;Ouvvi Documentation&lt;/a&gt; or send us an email.&lt;/p&gt;
&lt;p&gt;&lt;img src="http://www.simego.com/content/img/ouvvi-dashboard-example.png" alt="Ouvvi Automation Server" title="Ouvvi Automation Server" /&gt;&lt;/p&gt;
</description>
      <source url="http://www.simego.com/blog">Team Blog</source>
      <pubDate>Tue, 22 Feb 2022 10:00:00 +0000</pubDate>
    </item>
    <item>
      <link>http://www.simego.com/blog/export-active-directory-user-group-membership</link>
      <author>info@simego.com (Rebecca Allen)</author>
      <title>Managing Active Directory User Group Membership</title>
      <description>&lt;p&gt;Data Sync can be useful to assign users to groups in Active Directory and also export a list of users that are members of groups in your Active Directory.&lt;/p&gt;
&lt;p&gt;You might want an export to review current group membership, check that the correct users are in the correct groups, or be used to update another business system e.g. a SharePoint list.&lt;/p&gt;
&lt;div class="text-center"&gt;&lt;img src="https://images.simego.com/blog/activedirectory-groupmembership.png" title="Manage Active Directory Groups" alt="Manage Active Directory Groups"/&gt;
&lt;/div&gt;
&lt;section class="section-tiny alternate-color"&gt;
&lt;div class="container"&gt;
&lt;h3&gt;Contents&lt;/h3&gt;
&lt;ol&gt;
                    &lt;li&gt;
                        &lt;a href="#requirements"&gt;Requirements&lt;/a&gt;
                    &lt;/li&gt;
                    &lt;li&gt;
                        &lt;a href="#groups"&gt;Group Connector Options&lt;/a&gt;
                    &lt;/li&gt;
                    &lt;li&gt;
                        &lt;a href="#export"&gt;Export Group Membership&lt;/a&gt;
                    &lt;/li&gt;
                    &lt;li&gt;
                        &lt;a href="#groupmembership"&gt;Manage Group Membership&lt;/a&gt;
                    &lt;/li&gt;
                   &lt;li&gt;
                        &lt;a href="#users-group"&gt;Adding Groups to User Records&lt;/a&gt;
                    &lt;/li&gt;
                    &lt;ul&gt;
                        &lt;li&gt;
                            &lt;a href="#password"&gt;Set a Default Password&lt;/a&gt;
                        &lt;/li&gt;
                        &lt;li&gt;
                            &lt;a href="#manager"&gt;Assign a Manager&lt;/a&gt;
                        &lt;/li&gt;
                        &lt;li&gt;
                            &lt;a href="#enable"&gt;Enable User Accounts&lt;/a&gt;
                        &lt;/li&gt;
                        &lt;li&gt;
                            &lt;a href="#groups"&gt;Add to Groups&lt;/a&gt;
                        &lt;/li&gt;
                    &lt;/ul&gt;
                    &lt;li&gt;
                        &lt;a href="#preview"&gt;Preview and Sync the Results&lt;/a&gt;
                    &lt;/li&gt;
                    &lt;li&gt;
                        &lt;a href="#automate"&gt;Automate &amp;amp; Schedule&lt;/a&gt;
                    &lt;/li&gt;
                    &lt;li&gt;
                        &lt;a href="#video"&gt;Video - Adding Users&lt;/a&gt;
                    &lt;/li&gt;
                &lt;/ol&gt;
&lt;/div&gt;
&lt;/section&gt;
&lt;h2 id="requirements"&gt;Requirements&lt;/h2&gt;
&lt;p&gt;Before getting started you need to ensure you have the following:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Windows 10 or Windows Server&lt;/li&gt;
&lt;li&gt;Downloaded &amp;amp; Installed Data Synchronisation Studio&lt;/li&gt;
&lt;li&gt;A data set with your user details listed&lt;/li&gt;
&lt;li&gt;Access to Active Directory&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;If you do not have &lt;strong&gt;Data Synchronisation Studio&lt;/strong&gt; you can get a &lt;a href="/install/data-synchronisation-studio"&gt;free evaluation edition here&lt;/a&gt;.&lt;/p&gt;
&lt;h2 id="groups"&gt;Active Directory Group Connector Options&lt;/h2&gt;
&lt;p&gt;When connecting to Active Directory Groups you have a few options available, which you use depends on how your data is structured and whether you want to create groups at the same time.&lt;/p&gt;
&lt;p&gt;The Group Membership connector returns a list of all the groups within the connected Active Directory environment or organisational unit and the users that are members as separate rows.
This uses the &lt;strong&gt;Active Directory V2 - Group Members&lt;/strong&gt; connector, and can only be used to add and remove users from existing groups. An example of the dataset this produces can be seen below:&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/ad-groupmember-sampledata.png" alt="Group Membership Example Data" title="Group Membership Example Data" /&gt;&lt;/p&gt;
&lt;p&gt;The Groups connector returns a list of all the groups and a column with an array of the users that are members.
This uses the &lt;strong&gt;Active Directory V2 - Users/Contacts/Groups/Computers&lt;/strong&gt; connector with the &lt;strong&gt;Groups&lt;/strong&gt; connection and can be used to create groups if they do not already exist and add users to those groups. An example of how this looks as a dataset is:&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/ad-groupslist-sampledata.png" alt="Group List Example Data" title="Users Group List Example Data" /&gt;&lt;/p&gt;
&lt;p&gt;If your data has a list of users with an array column containing the groups they are members of, then you can use the &lt;strong&gt;Active Directory V2 - Users/Contacts/Groups/Computers&lt;/strong&gt; connector with the &lt;strong&gt;Users&lt;/strong&gt; connection.
An example of how this looks as a dataset is:&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/ad-groupsusers-sampledata.png" alt="Users List Example Data" title="Users List Example Data" /&gt;&lt;/p&gt;
&lt;p&gt;We cover using each of these in different scenarios in the next sections.&lt;/p&gt;
&lt;p&gt;If you need to get your data from group members to an array of members then you can do so with a SQL statement.
The statement below aggregates the members for each group into an array separated by a semi colon, grouped by the group name.&lt;/p&gt;
&lt;div class="lang-SQL editor-colors"&gt;&lt;div style="color:Black;background-color:White;"&gt;&lt;pre&gt;
&lt;span style="color:Blue;"&gt;SELECT&lt;/span&gt; [Group],
STRING_AGG([Members], &lt;span style="color:#A31515;"&gt;&amp;#39;;&amp;#39;&lt;/span&gt;) WITHIN &lt;span style="color:Blue;"&gt;GROUP&lt;/span&gt; (&lt;span style="color:Blue;"&gt;ORDER&lt;/span&gt; &lt;span style="color:Blue;"&gt;BY&lt;/span&gt; [Members] &lt;span style="color:Blue;"&gt;ASC&lt;/span&gt; )
&lt;span style="color:Blue;"&gt;FROM&lt;/span&gt; [Groups]
&lt;span style="color:Blue;"&gt;GROUP&lt;/span&gt; &lt;span style="color:Blue;"&gt;BY&lt;/span&gt; [Group]
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;p&gt;You can then use this data set with &lt;strong&gt;Active Directory V2 - Users/Contacts/Groups/Computers&lt;/strong&gt; connector.&lt;/p&gt;
&lt;h2 id="export"&gt;Export Group Membership&lt;/h2&gt;
&lt;p&gt;To export the Group Membership you need to first connect to Active Directory. Decide how you would like your data returning either separate rows for each member in a group or an array of members against each group.&lt;/p&gt;
&lt;p&gt;For this example we will use the &lt;strong&gt;Group Membership&lt;/strong&gt; connector to return a list of all the groups and all the users contained in the groups.&lt;/p&gt;
&lt;p&gt;Start by connecting to your Active Directory Groups Members. To do this click open the connection window and go to &lt;strong&gt;Active Directory&lt;/strong&gt; &amp;gt; &lt;strong&gt;Active Directory V2 - Group Members&lt;/strong&gt;.&lt;/p&gt;
&lt;p&gt;Then decide if you want to export it to a business system or as a simple CSV, Excel, XML or JSON file.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/ad-groupmembers-connection.png" alt="Group Membership Connection" title="Group Membership Connection" /&gt;&lt;/p&gt;
&lt;h3 id="export-to-a-file"&gt;Export to a File&lt;/h3&gt;
&lt;p&gt;To export your members list to a file, you can either use the create functions from the tools menu or you can use the export options on the preview tab.&lt;/p&gt;
&lt;p&gt;Start by adding the columns you want to include in your export to the schema map.&lt;/p&gt;
&lt;p&gt;Then to export to a file, click onto &lt;strong&gt;Preview A&lt;/strong&gt;.
You can then choose from the export options which file type you would like and then save the file. Choose between an Excel spreadsheet, a CSV, XML or JSON file.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/preview-export-options.png" alt="Export Options - Preview Tab" title="Export Options - Preview Tab" /&gt;&lt;/p&gt;
&lt;p&gt;Alternatively you can use the tools menu to create a new CSV or XML file. Just go to Tools and select the option you would like. Select the location to save the file and click save.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/tools-menu-createoptions.png" alt="Tools Menu Options" title="Tools Menu Options" /&gt;&lt;/p&gt;
&lt;p&gt;Then check the schema mapping, and make sure you have defined a key column. The key column for the group membership is going to be a composite key as the group is not unique.
Your mapping might look similar to this:&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/ad-groupmembers-mapping.png" alt="Group Membership Export Mapping" title="Group Membership Export Mapping" /&gt;&lt;/p&gt;
&lt;p&gt;To synchronise the data just click Compare A &amp;gt; B and sync the results.&lt;/p&gt;
&lt;h3 id="export-to-a-business-system"&gt;Export to a Business System&lt;/h3&gt;
&lt;p&gt;To export your members list to another business system, for example a SharePoint List or a SQL Table, you can simply connect your target to the list or table if it already exists.&lt;/p&gt;
&lt;p&gt;If you need to create a new list or SQl table you can make use of the quick create functions to create them. Just open the Tools menu and select the option you would like to use.
For example to create a new SQL table you can select &lt;strong&gt;Create Sql Table&lt;/strong&gt; and then follow the instructions in the wizard to create it. The columns will be populated based upon the columns/attributes added to the schema map.&lt;/p&gt;
&lt;p&gt;Make sure to set your key columns, this needs to be identifying so that each record appears as unique. In this example we need to use a composite key, so both the Group AccountName and the User AccountName.&lt;/p&gt;
&lt;p&gt;To add the data to the table click &lt;strong&gt;Compare A &amp;gt; B&lt;/strong&gt; followed by &lt;strong&gt;Synchronise&lt;/strong&gt; and then &lt;strong&gt;Start&lt;/strong&gt;. You can preview the results before synchronising to make sure the data presents as expected.
Below you can see an example of the preview results, where we have 11 records to add.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/ad-groupmembers-compareresults.png" alt="Compare Results" title="Compare Results" /&gt;&lt;/p&gt;
&lt;p&gt;Make sure to save your project for future use. You might want to schedule it to run on a regular basis using either the &lt;a href="/docs/data-sync/run-tool/intro"&gt;Run Tool&lt;/a&gt; or &lt;a href="/docs/ouvvi/userguide/intro"&gt;Ouvvi Automation Server&lt;/a&gt;.&lt;/p&gt;
&lt;h2 id="groupmembership"&gt;Manage Group Membership&lt;/h2&gt;
&lt;p&gt;To manage group membership in Active Directory you can use a source dataset to add and remove users from groups. It depends on how your data is presented in your source system as to which Active Directory connector you will use in Data Sync.&lt;/p&gt;
&lt;p&gt;If your dataset has the users listed against the groups, for example:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Group 1 | User A&lt;/li&gt;
&lt;li&gt;Group 1 | User B&lt;/li&gt;
&lt;li&gt;Group 2 | User A&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;Then you will use the &lt;strong&gt;Active Directory V2 - Group Membership&lt;/strong&gt; connector.&lt;/p&gt;
&lt;p&gt;If your dataset lists the groups and the members within that group as an array (separated by a semi-colon) then you can use the normal &lt;strong&gt;Active Directory V2 - Users/Contacts/Groups/Computers&lt;/strong&gt; connector.&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Group 1 | User 1;User 2&lt;/li&gt;
&lt;li&gt;Group 2 | User 1&lt;/li&gt;
&lt;li&gt;Group 3 | User1;User3;User5&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;To create new groups you will need to ensure you are connected using the &lt;strong&gt;Groups&lt;/strong&gt; option in the Default Attributes connection property as all the other types do not support group creation.&lt;/p&gt;
&lt;p&gt;In the following example we have groups with the members listed as an array, this will be being updated with data stored in a SQL Table. There will be a few groups listed in the source that are not yet in Active Directory.&lt;/p&gt;
&lt;h3 id="source"&gt;Connect to your Source Data&lt;/h3&gt;
&lt;p&gt;Start by opening Data Sync and connecting to your source data. You can use any of the built in connectors in Data Sync or build your own connector if we do not have one readily available.&lt;/p&gt;
&lt;p&gt;For this example we are connecting to a SQL Table that has the group AccountName and a column containing an array of the users that should be members.
This dataset looks like this:&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/ad-groupslist-sampledata.png" alt="Users Group List Example Data" title="Users Group List Example Data" /&gt;&lt;/p&gt;
&lt;h3 id="target"&gt;Connect to your Active Directory Groups&lt;/h3&gt;
&lt;p&gt;You now need to connect to Active Directory.
To do this click onto &lt;strong&gt;Connect Datasource&lt;/strong&gt; in the target window and go to &lt;strong&gt;Active Directory&lt;/strong&gt; &amp;gt; &lt;strong&gt;Active Directory V2 - Users/Contacts/Groups/Computers&lt;/strong&gt;.&lt;/p&gt;
&lt;p&gt;As this project is specifically updating groups we need to change the &lt;strong&gt;DefaultAttributes&lt;/strong&gt; property to &lt;strong&gt;Groups&lt;/strong&gt;. If you wanted to modify other attributes alongside the group membership then you could leave the DefaultAttributes property set to &lt;strong&gt;Users&lt;/strong&gt;, but we discuss this in more detail in the &lt;a href="#users-groups"&gt;next section&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;Then enter in the LDAP path to your Active Directory instance, and enter in any credentials you need to access AD.
You can enter in the full LDAP path (including the server name) or just the server name.&lt;/p&gt;
&lt;p&gt;If you just use the server name your path would look similar to: &lt;code&gt;LDAP://dc01&lt;/code&gt;.&lt;br /&gt;
Otherwise an example path connecting to a specific OU could be: &lt;code&gt;LDAP://dc01/OU=Test,DC=demo,DC=simego,DC=com&lt;/code&gt;.&lt;/p&gt;
&lt;p&gt;We have more details on finding the LDAP Path in our &lt;a href="/docs/data-sync/connectors/ad/ldap"&gt;documentation&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/ad-groups-connection.png" alt="AD Connection Details" title="AD Connection Details" /&gt;&lt;/p&gt;
&lt;p&gt;Then click &lt;strong&gt;Connect &amp;amp; Create Library Connection&lt;/strong&gt; to save the connection to the connection library. Enter in a name for the connection into the windows that pops up and click OK.
You can refresh the connection library window (to the left of the Data Sync window) and your Active Directory connection will now be visible in the list.&lt;/p&gt;
&lt;p&gt;This only needs to be done once per OU as you will be able to access other objects such as Users and Contacts from the connection window.&lt;/p&gt;
&lt;p&gt;If you have already saved your connection to AD you can select the Groups object from your AD connection.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/ad-groups-connectionlibrary.png" alt="Connection Library - Active Directory Groups" title="Connection Library - Active Directory Groups" /&gt;&lt;/p&gt;
&lt;h3 id="mapping"&gt;Map the columns&lt;/h3&gt;
&lt;p&gt;Now map the source columns to their corresponding attributes in Active Directory.
Make sure to map the user array to the &lt;strong&gt;DS-MemberNames&lt;/strong&gt; column as this will handle the lookup of the user names for you.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/ad-groupsmembership-mapping.png" alt="Mapping" title="Mapping" /&gt;&lt;/p&gt;
&lt;p&gt;Make sure to set the &lt;strong&gt;Group SAMAccountName&lt;/strong&gt; as the key column so that each group can be identified.&lt;/p&gt;
&lt;h3 id="preview"&gt;Preview the Results &amp;amp; Sync&lt;/h3&gt;
&lt;p&gt;Once you have configured the schema map you can preview the results before synchronising.&lt;/p&gt;
&lt;p&gt;To do this click on the &lt;strong&gt;Compare A &amp;gt; B&lt;/strong&gt; button in the toolbar, this will display the number of records to be added, updated and deleted.
Please note that deletes are disabled by default but will still show in the compare results. To enable them please set EnableDelete to True in the target connection properties.&lt;/p&gt;
&lt;p&gt;You can preview the data changes by clicking onto each section. In this example we have 2 groups to create and 2 groups to update.
Clicking onto the result rows will show the data to be changed.&lt;/p&gt;
&lt;p&gt;For updates any changes are highlighted in yellow.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/ad-groupmembership-compare-add.png" alt="Preview Results - Additions" title="Preview Results - Additions" /&gt;&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/ad-groupmembership-compare-update.png" alt="Preview Results - Updates" title="Preview Results - Updates" /&gt;&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;Please note that deletes are disabled by default but will still show in the results if the group is not present in the source data. To enable deletes set EnableDelete to True on the target connection properties.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;Once you are ready to apply the changes to Active Directory click onto the &lt;strong&gt;Synchronise&lt;/strong&gt; button and then click &lt;strong&gt;Start&lt;/strong&gt;.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/ad-groupmembership-syncresults.png" alt="Synchronise" title="Synchronise" /&gt;&lt;/p&gt;
&lt;p&gt;Your users will now be added to their relevant groups, and if the group did not exist it will now be created.&lt;/p&gt;
&lt;p&gt;Make sure to save your project so that you can use it again in the future.&lt;/p&gt;
&lt;p&gt;If you would like to schedule your project to run automatically you can do so using either the &lt;a href="/docs/data-sync/run-tool/intro"&gt;Run Tool&lt;/a&gt; or &lt;a href="/docs/ouvvi/userguide/intro"&gt;Ouvvi Automation Server&lt;/a&gt; with both event and time based triggers.&lt;/p&gt;
&lt;h2 id="users-groups"&gt;Adding Groups to User records&lt;/h2&gt;
&lt;p&gt;You can also manage group membership when adding and updating existing users in Active Directory.
Your user records need to have the groups they are a member of listed in a column separated by a semi-colon.&lt;/p&gt;
&lt;p&gt;An example of how this might look in a dataset is:&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/ad-groupsusers-sampledata.png" alt="Groups to Users" title="Groups to Users" /&gt;&lt;/p&gt;
&lt;p&gt;Connect to Active Directory as normal using the &lt;strong&gt;Active Directory V2- Users/Contacts/Groups/Computers&lt;/strong&gt; connector and make sure the DefaultAttributes is set to users.&lt;/p&gt;
&lt;p&gt;Then map your group array column to the schema map and make sure to include a key column to identify the user. We recommend using the SAMAccountName as this will always be unique.
In this example we are also updating the manager email address so this is also added to the schema map.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/ad-usersgroups-mapping.png" alt="Mapping" title="Mapping" /&gt;&lt;/p&gt;
&lt;p&gt;Then run the compare and preview the results. Once you are satisfied that the columns are mapped correctly click &lt;strong&gt;Synchronise&lt;/strong&gt; and then &lt;strong&gt;Start&lt;/strong&gt; to begin the sync.&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;Please note that if your groups do not already exist in Active Directory then an error will be thrown. You will need to use the Groups connector to be able to create new groups.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;If you're looking to synchronise Active Directory group members to a SharePoint security group take a look at our &lt;a href="/blog/sync-active-directory-group-members-to-sharepoint-security-group"&gt;other blog here&lt;/a&gt;.&lt;/p&gt;
</description>
      <source url="http://www.simego.com/blog">Team Blog</source>
      <pubDate>Fri, 25 Feb 2022 10:04:44 +0000</pubDate>
    </item>
    <item>
      <link>http://www.simego.com/blog/bulk-update-active-directory</link>
      <author>info@simego.com (Rebecca Allen)</author>
      <title>Bulk Update Active Directory</title>
      <description>&lt;p&gt;You can use Data Sync to apply large updates or additions to your Active Directory records with a few easy steps.&lt;/p&gt;
&lt;p&gt;You may need to change the enabled or disabled status of a large quantity of users, or you might have added a new metadata column for all users stored within a SharePoint list and this needs to be applied to each Active Directory record.
With Data Sync you simple connect, map, compare and sync, and your changes will be applied.&lt;/p&gt;
&lt;p&gt;Below we discuss setting up a project to add 800+ new users, and update 160 records with an additional column of data and an account status change.&lt;/p&gt;
&lt;section class="section-tiny alternate-color"&gt;
&lt;div class="container"&gt;
&lt;h3&gt;Contents&lt;/h3&gt;
&lt;ol&gt;
                    &lt;li&gt;
                        &lt;a href="#requirements"&gt;Requirements&lt;/a&gt;
                    &lt;/li&gt;
                    &lt;li&gt;
                        &lt;a href="#connect"&gt;Connect to your Source and Target&lt;/a&gt;
                    &lt;/li&gt;
                    &lt;li&gt;
                        &lt;a href="#mapping"&gt;Mapping&lt;/a&gt;
                    &lt;/li&gt;
                    &lt;li&gt;
                        &lt;a href="#preview"&gt;Preview the Results and Sync&lt;/a&gt;
                    &lt;/li&gt;                   
                &lt;/ol&gt;
&lt;/div&gt;
&lt;/section&gt;
&lt;h2 id="requirements"&gt;Requirements&lt;/h2&gt;
Before you get started there are a few requirements:
&lt;ul&gt;
&lt;li&gt;Windows 10 or Windows Server&lt;/li&gt;
&lt;li&gt;Downloaded &amp;amp; Installed Data Synchronisation Studio&lt;/li&gt;
&lt;li&gt;Access to Active Directory&lt;/li&gt;
&lt;li&gt;A data set containing the records you want to add&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;If you do not have &lt;strong&gt;Data Synchronisation Studio&lt;/strong&gt; you can get a &lt;a href="/install/data-synchronisation-studio"&gt;free evaluation edition here&lt;/a&gt;.&lt;/p&gt;
&lt;h2 id="connect"&gt;Connect to your Source and Target&lt;/h2&gt;
&lt;p&gt;To get started open Data Sync and connect to your source data, you can connect using any of the &lt;a href="/docs/data-sync-connectors"&gt;inbuilt connectors&lt;/a&gt; or &lt;a href="/docs/data-sync/connectors/connector-sdk/connector-sdk"&gt;build your own&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;Then connect the target window to Active Directory.
The default attribute to select in the connection will depend on the data you want to add. In this example we are adding to user records but you can change this as you need to and each type will follow the same process.&lt;/p&gt;
&lt;p&gt;To connect to the user records in Active Directory we need to click onto &lt;strong&gt;Connect Datasource&lt;/strong&gt; in the target window and go to &lt;strong&gt;Active Directory&lt;/strong&gt; &amp;gt; &lt;strong&gt;Active Directory V2 - Users/Contacts/Groups/Computers&lt;/strong&gt;.&lt;/p&gt;
&lt;p&gt;By default &lt;strong&gt;Users&lt;/strong&gt; will be selected from the DefaultAttributes drop-down menu, enter in the LDAP path to your Active Directory instance, and enter in any credentials you need to access AD.&lt;/p&gt;
&lt;p&gt;You can enter in the full LDAP path (including the server name) or just the server name.&lt;br /&gt;
If you just use the server name your path would look similar to: &lt;code&gt;LDAP://dc01&lt;/code&gt;.&lt;br /&gt;
Otherwise an example path connecting to a specific OU could be: &lt;code&gt;LDAP://dc01/OU=Test,DC=demo,DC=simego,DC=com&lt;/code&gt;.&lt;/p&gt;
&lt;p&gt;We have more details on finding the LDAP Path in our &lt;a href="/docs/data-sync/connectors/ad/ldap"&gt;documentation&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/ad-users-connection.png" alt="AD Connection Details" title="AD Connection Details" /&gt;&lt;/p&gt;
&lt;p&gt;Then click &lt;strong&gt;Connect &amp;amp; Create Library Connection&lt;/strong&gt; to save the connection to the connection library. Just enter in a name for the connection and click OK. Then refresh the connection window and your Active Directory connection will be visible in the list.&lt;/p&gt;
&lt;p&gt;This only needs to be done once per OU as you will be able to access other objects such as Groups and Contacts from the connection window.&lt;/p&gt;
&lt;p&gt;If you have already saved your connection to AD you can select the Users object from your AD connection. To do this right click onto &lt;strong&gt;Users&lt;/strong&gt; object and select &lt;strong&gt;Connect to Target (B)&lt;/strong&gt; or drag the object onto the target window.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/ad-users-connectionlibrary.png" alt="Connection Library - Active Directory Users" title="Connection Library - Active Directory Users" /&gt;&lt;/p&gt;
&lt;h2 id="mapping"&gt;Mapping&lt;/h2&gt;
&lt;p&gt;The next step is to map the columns you want to update and make sure to add a key column that can be used to identify each user.
For users we recommend using either the SAMAccountName or the Email Address as these will always be unique.&lt;/p&gt;
&lt;p&gt;Add the source columns to the schema map and match them to their corresponding Active Directory attribute.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/ad-bulkupdate-mapping.png" alt="Mapping" title="Mapping" /&gt;&lt;/p&gt;
&lt;h2 id="preview"&gt;Preview the Results and Sync&lt;/h2&gt;
&lt;p&gt;Now we need to run the compare to preview the results before synchronising.
To do this click onto the &lt;strong&gt;Compare A &amp;gt; B&lt;/strong&gt; button in the toolbar, and then select a row to view either the adds, updates or deletes.&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;NB. Deletes are disabled by default but will still show in the results if the records do not exist in the source data set. To enable deletes set EnableDelete to True in the target connection properties.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;In this example we have 840 records to add to the target and 160 records to update. Below you can see that the update actions are highlighted in yellow.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/ad-bulkupdate-preview.png" alt="Preview Results" title=" Preview Results" /&gt;&lt;/p&gt;
&lt;p&gt;Make sure to take a quick glance through to ensure the data looks right and then click &lt;strong&gt;Synchronise&lt;/strong&gt; and &lt;strong&gt;Start&lt;/strong&gt; to begin the sync.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/ad-bulkupdate-sync.png" alt="Synchronise" title="Synchronise" /&gt;&lt;/p&gt;
&lt;p&gt;Your Active Directory records will then be added and updated where necessary.&lt;/p&gt;
&lt;p&gt;Make sure to save your project in-case you need to use it again in the future. You can always modify it to include more columns.&lt;/p&gt;
</description>
      <source url="http://www.simego.com/blog">Team Blog</source>
      <pubDate>Wed, 02 Mar 2022 10:14:11 +0000</pubDate>
    </item>
    <item>
      <link>http://www.simego.com/blog/create-script-table-from-schema</link>
      <author>info@simego.com (Rebecca Allen)</author>
      <title>Creating Database Scripts from the Schema Map</title>
      <description>&lt;p&gt;A feature available in Data Sync, that you may not already know about, is the ability to generate script to create new tables in your Database based upon the columns you add to the schema map window.&lt;/p&gt;
&lt;p&gt;You can edit the configuration before generating the script; such as changing the column names, data types and data lengths.&lt;/p&gt;
&lt;p&gt;To generate the script you simply click a button.&lt;/p&gt;
&lt;p&gt;We then go a step further and enable you to connect to your database and run the script from Data Sync.
Before running the script if you want to add to it you can.&lt;/p&gt;
&lt;p&gt;This works in a similar way to the &lt;a href="/docs/data-sync/userguide/sql-query-tool"&gt;SQL Query Tool&lt;/a&gt;.&lt;/p&gt;
&lt;div class="text-center"&gt;&lt;img src="https://images.simego.com/blog/script-sql-table-outputs.png" title="SQL Script Overview" alt="SQL Script Overview"/&gt;&lt;/div&gt;
&lt;section class="section-tiny alternate-color"&gt;
&lt;div class="container"&gt;
&lt;h3&gt;Contents&lt;/h3&gt;
&lt;ol&gt;
                    &lt;li&gt;
                        &lt;a href="#requirements"&gt;Requirements&lt;/a&gt;
                    &lt;/li&gt;
                    &lt;li&gt;
                        &lt;a href="#connect"&gt;Connect to your Source&lt;/a&gt;
                    &lt;/li&gt;
                    &lt;li&gt;
                        &lt;a href="#script"&gt;Generate the Script&lt;/a&gt;
                    &lt;/li&gt;
                    &lt;li&gt;
                        &lt;a href="#target"&gt;Set the New Table as the Target&lt;/a&gt;
                    &lt;/li&gt;
                   &lt;li&gt;
                        &lt;a href="#mapping"&gt;Map the Source &amp;amp; Target Columns&lt;/a&gt;
                    &lt;/li&gt;
                    &lt;li&gt;
                        &lt;a href="#compare"&gt;Compare the Results and Sync&lt;/a&gt;
                    &lt;/li&gt;
                &lt;/ol&gt;
&lt;/div&gt;
&lt;/section&gt;
&lt;h2 id="requirements"&gt;Requirements&lt;/h2&gt;
&lt;p&gt;Before getting started you need to ensure you have the following:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Windows 10 or Windows Server&lt;/li&gt;
&lt;li&gt;Downloaded &amp;amp; Installed Data Synchronisation Studio&lt;/li&gt;
&lt;li&gt;A dataset to base the script off&lt;/li&gt;
&lt;li&gt;Access to a database (either SQL Server, MySQL or PostgreSQL)&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;If you are connecting to PostgreSQL or MySQL please make sure you have the relevant ADO.net drivers installed.&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;MySQL: &lt;a href="https://dev.mysql.com/downloads/connector/net/" target="_blank"&gt;https://dev.mysql.com/downloads/connector/net/ &lt;/a&gt;&lt;/li&gt;
&lt;li&gt;PostgreSQL: &lt;a href="https://github.com/npgsql/npgsql/releases/tag/v4.0.12" target="_blank"&gt;https://github.com/npgsql/npgsql/releases/tag/v4.0.12 &lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;If you do not have &lt;strong&gt;Data Synchronisation Studio&lt;/strong&gt; you can get a &lt;a href="/install/data-synchronisation-studio"&gt;free evaluation edition&lt;/a&gt;.&lt;/p&gt;
&lt;h2 id="connect"&gt;Connect to your Source&lt;/h2&gt;
&lt;p&gt;You need to start by connecting to a datasource that you can base your schema off. This might be the dataset you want to ultimately import into your new table once it has been created.&lt;/p&gt;
&lt;p&gt;In this example we have a simple CSV file with a number of columns describing contacts. You can use any of the providers built into Data Sync or you can write your own to connect to your business systems.&lt;/p&gt;
&lt;p&gt;To connect to a CSV file you can either drag and drop the file from the file explorer onto the source window or you can browse for the file in the connection window.
Then click onto &lt;strong&gt;Connect Datasource&lt;/strong&gt; &amp;gt; &lt;strong&gt;Text Files&lt;/strong&gt; &amp;gt; &lt;strong&gt;CSV File&lt;/strong&gt; and browse for your CSV by clicking onto the ellipsis in the &lt;strong&gt;FileName&lt;/strong&gt; field.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/datasync-connect-csvfile.png" alt="Connect to CSV" title="Connect to CSV" /&gt;&lt;/p&gt;
&lt;p&gt;Then add the columns you want to create in the new table to the schema map and move onto the next step to configure and generate the script.&lt;/p&gt;
&lt;h2 id="script"&gt;Generate the Script&lt;/h2&gt;
&lt;p&gt;In the schema window toolbar you can find the &lt;strong&gt;Generate SQL Script&lt;/strong&gt; button. Click on this to open the configuration window.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/datasync-generatescript-button-contact.png" alt="Generate Script Button" title="Generate Script Button" /&gt;&lt;/p&gt;
&lt;p&gt;You are first presented with a window to define the table name and select a connection to the Database you want to create the table in. If you want to run the script outside of Data Sync then you can leave this blank.
You can also define the type of database and script you want to generate. These settings can also be changed later on.&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;You can only select connections saved in your connection library. If you have not saved your connection you will need to open a new Data Sync project, create and save the database connection to the connection library before you can connect in the SQL Script Generator.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/datasync-generatescript-connection.png" alt="Generate Script Connection" title="Generate Script Connection" /&gt;&lt;/p&gt;
&lt;p&gt;The Script window will then be opened and you can now add additional columns and change column names, data types and data lengths.
If you defined a key column in the schema map this will be identified as the primary key column in the configuration.
If you need to set a composite key, you can do so here.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/datasync-generatescript-configuration.png" alt="Edit configuration" title="Edit Configuration" /&gt;&lt;/p&gt;
&lt;p&gt;To generate the script click onto the &lt;strong&gt;Script Create Table&lt;/strong&gt; in the window toolbar.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/datasync-generatescript-scriptcreate.png" alt="Generate Script" title="Generate Script" /&gt;&lt;/p&gt;
&lt;p&gt;This will generate the script in a window below the columns.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/datasync-generatescript-viewscript.png" alt="Script Generated - SQL Server" title="Script Generated" /&gt;&lt;/p&gt;
&lt;p&gt;You can make edits and additions to this script, copy it or run it directly from Data Sync.
To run the script on the database connection you listed at the start click onto the &lt;strong&gt;Execute Query&lt;/strong&gt; button.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/datasync-generatescript-executequery.png" alt="Execute Query" title="Execute Query" /&gt;&lt;/p&gt;
&lt;p&gt;Your table will now be created in the Database specified. If you refresh your connection library and navigate to your connection. You should now be able to see your table in the list.&lt;/p&gt;
&lt;h2 id="target"&gt;Set the New Table as the Target&lt;/h2&gt;
&lt;p&gt;You most likely now want to synchronise data to the new table. To do this you need to connect your target to the table.&lt;/p&gt;
&lt;p&gt;As this is stored in the connection library you can find your database connection, open the tables folder and either drag and drop or right click and select &lt;strong&gt;Set as Target&lt;/strong&gt;.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/datasync-mycontacts-connectionlib-options.png" alt="Connection Library Connection" title="Connection Library Connection" /&gt;&lt;/p&gt;
&lt;h2 id="mapping"&gt;Map the Source &amp;amp; Target Columns&lt;/h2&gt;
&lt;p&gt;Now check that the source and target columns all match and ensure you have selected your key column to identify each record.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/datasync-generatescript-mapping.png" alt="Mapping" title="Mapping" /&gt;&lt;/p&gt;
&lt;h2 id="compare"&gt;Compare the Results and Sync&lt;/h2&gt;
&lt;p&gt;You can then click the &lt;strong&gt;Compare A &amp;gt; B&lt;/strong&gt; button in the toolbar to preview the results.
As this is a new table we will only see additions, but if you run the project again at a later date we may also see updates and deletions.&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;Deletes are disabled by default but will still show in the results. To enable deletes set &lt;strong&gt;EnableDelete&lt;/strong&gt; to True on the target.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/datasync-generatescript-previewcompare.png" alt="Compare Results" title="Compare Results" /&gt;&lt;/p&gt;
&lt;p&gt;To synchronise the results click &lt;strong&gt;Synchronise&lt;/strong&gt; and then &lt;strong&gt;Start&lt;/strong&gt; to begin the sync.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/datasync-generatescript-synchronise.png" alt="Synchronise" title="Synchronise" /&gt;&lt;/p&gt;
&lt;p&gt;Your data will then be visible in your new table. Make sure to save the final project so that you can run the future synchronisation again in the future.&lt;/p&gt;
&lt;h2 id="misc"&gt;Miscellaneous&lt;/h2&gt;
&lt;p&gt;Whilst using the SQL Table Script Generator you can edit the configuration you initially determined at the beginning. You can change the script language, change the name of the table to be created, and edit the database connection details.&lt;/p&gt;
&lt;h3 id="edit-the-script-language"&gt;Edit the Script Language&lt;/h3&gt;
&lt;p&gt;You can edit the language the script is generated by selecting between SQL Server, MySQL, and PostgreSQL in the drop down in the toolbar window.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/datasync-generatescript-changelanguage.png" alt="Change Script Language" title="Change Script Language" /&gt;&lt;/p&gt;
&lt;h3 id="edit-the-table-name"&gt;Edit the Table Name&lt;/h3&gt;
&lt;p&gt;To edit the name of the table to be generated, and listed within the script, click onto the current name field in the toolbar of the window and simply make the changes you need.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/datasync-generatescript-edittablename.png" alt="Edit the Table Name" title="Edit the Table Name" /&gt;&lt;/p&gt;
&lt;h3 id="change-the-database-connection-details"&gt;Change the Database Connection Details&lt;/h3&gt;
&lt;p&gt;To change the database connection details you can click onto the connection in the script editor. This will open the Connection Properties for the connection you selected at the start. Make the changes you need and then click OK to save them.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/datasync-generatescript-editconnection.png" alt="Edit the Database Connection" title="Edit the Database Connection" /&gt;&lt;/p&gt;
&lt;h3 id="execute-selected-script"&gt;Execute Selected Script&lt;/h3&gt;
&lt;p&gt;If you add additional script to the script generated by Data Sync, for example a SELECT query, then you can run just that script by highlighting it and then clicking &lt;strong&gt;Execute Query&lt;/strong&gt;.&lt;/p&gt;
&lt;p&gt;Taking the example we used above if I wanted to preview the records within that table after I had run the synchronisation I could use the query:&lt;/p&gt;
&lt;p&gt;&lt;code&gt;SELECT * FROM MyContact&lt;/code&gt;&lt;/p&gt;
&lt;p&gt;Highlighting this query and clicking the &lt;strong&gt;Execute Script&lt;/strong&gt; button will then bring up my data in the preview window below the script.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/datasync-generatescript-previewrecords.png" alt="Preview Data" title="Preview Data" /&gt;&lt;/p&gt;
&lt;p&gt;In the preview window you can also edit the records manually by double clicking onto the field you want to edit. Clicking out of that field will apply the changes.&lt;/p&gt;
&lt;p&gt;If you are looking to run other SQL queries in Data Sync then you can do so using the SQL Query Tool. &lt;a href="/docs/data-sync/userguide/sql-query-tool"&gt;Check out our documentation&lt;/a&gt; for more information.&lt;/p&gt;
</description>
      <source url="http://www.simego.com/blog">Team Blog</source>
      <pubDate>Thu, 24 Mar 2022 10:00:00 +0000</pubDate>
    </item>
    <item>
      <link>http://www.simego.com/blog/integrating-with-salesforce</link>
      <author>info@simego.com (Rebecca Allen)</author>
      <title>Integrating with Salesforce</title>
      <description>&lt;p&gt;With Data Sync you can quickly and easily import and export data to and from your Salesforce objects.&lt;/p&gt;
&lt;p&gt;Below we cover importing contact records into the contact object from a SQL table, and then we cover how to export the Salesforce account object into a SQL table.&lt;/p&gt;
&lt;p&gt;Although we use the example of a SQL table in this article, you can use any of the available connectors to import and export data. If there is not currently a connector for your system then you can always &lt;a href="/docs/data-sync/connectors/connector-sdk/connector-sdk"&gt;build a custom connector&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;Note that when designing your integration with Salesforce you need to think about the relationship between objects. There may be relational fields that are dependant on values being added in another object first before they can be used in the one your project is updating.&lt;/p&gt;
&lt;p&gt;For example the contact object has the Account ID which links it to the account object.
If you try to add a contact for an account that doesn't exist in the account object then it is likely to fail. To get around this issue you should make sure that the account object is updated before the contact object.&lt;/p&gt;
&lt;div class="text-center"&gt;&lt;img src="https://images.simego.com/blog/salesforce-integration.png" title="Salesforce Sync" alt="Salesforce Sync"/&gt;&lt;/div&gt;
&lt;section class="section-tiny alternate-color"&gt;
&lt;div class="container"&gt;
&lt;h3&gt;Contents&lt;/h3&gt;
&lt;ol&gt;
                    &lt;li&gt;
                        &lt;a href="#requirements"&gt;Requirements&lt;/a&gt;
                    &lt;/li&gt;
                    &lt;li&gt;
                        &lt;a href="#import"&gt;Importing Data into Salesforce&lt;/a&gt;
                    &lt;/li&gt;
                    &lt;ul&gt;
                        &lt;li&gt;
                            &lt;a href="#connect"&gt;Connect to your Source Data&lt;/a&gt;
                        &lt;/li&gt;
                        &lt;li&gt;
                            &lt;a href="#salesforce"&gt;Connect to Salesforce&lt;/a&gt;
                        &lt;/li&gt;
                        &lt;li&gt;
                            &lt;a href="#mapping"&gt;Map the Source &amp;amp; Target Columns&lt;/a&gt;
                        &lt;/li&gt;
                        &lt;li&gt;
                            &lt;a href="#compare"&gt;Preview the Results and Sync&lt;/a&gt;
                        &lt;/li&gt;
                    &lt;/ul&gt;
                    &lt;li&gt;
                        &lt;a href="#export"&gt;Exporting Data from Salesforce&lt;/a&gt;
                    &lt;/li&gt;                    
                    &lt;ul&gt;
                        &lt;li&gt;
                            &lt;a href="#connect-salesforce"&gt;Connect to Salesforce&lt;/a&gt;
                        &lt;/li&gt;
                        &lt;li&gt;
                            &lt;a href="#connect-sql"&gt;Connect to your SQL Table&lt;/a&gt;
                        &lt;/li&gt;
                        &lt;li&gt;
                            &lt;a href="#map-columns"&gt;Map the Source &amp;amp; Target Columns&lt;/a&gt;
                        &lt;/li&gt;
                        &lt;li&gt;
                            &lt;a href="#sync"&gt;Preview the Results and Sync&lt;/a&gt;
                        &lt;/li&gt;
                    &lt;/ul&gt;
                    &lt;li&gt;
                        &lt;a href="#misc"&gt;Additional Options&lt;/a&gt;
                    &lt;/li&gt;
                    &lt;ul&gt;
                        &lt;li&gt;
                            &lt;a href="#filter"&gt;Filtering the Results&lt;/a&gt;
                        &lt;/li&gt;
                        &lt;li&gt;
                            &lt;a href="#schedule"&gt;Automate &amp; Schedule&lt;/a&gt;
                        &lt;/li&gt;
                        &lt;li&gt;
                            &lt;a href="#troubleshoot"&gt;Troubleshooting&lt;/a&gt;
                        &lt;/li&gt;
                    &lt;/ul&gt;
                &lt;/ol&gt;
&lt;/div&gt;
&lt;/section&gt;
&lt;h2 id="requirements"&gt;Requirements&lt;/h2&gt;
&lt;p&gt;Before getting started you need to ensure you have the following:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Windows 10 or Windows Server&lt;/li&gt;
&lt;li&gt;Downloaded &amp;amp; Installed Data Synchronisation Studio&lt;/li&gt;
&lt;li&gt;Access to Salesforce&lt;/li&gt;
&lt;li&gt;A dataset to connect to&lt;/li&gt;
&lt;li&gt;Access to a SQL table, or another system to export your data to.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;If you do not have &lt;strong&gt;Data Synchronisation Studio&lt;/strong&gt; you can get a &lt;a href="/install/data-synchronisation-studio"&gt;free evaluation edition&lt;/a&gt;.&lt;/p&gt;
&lt;h2 id="import"&gt;Importing Data into Salesforce&lt;/h2&gt;
&lt;p&gt;You can quickly and easily synchronise your business data into Salesforce when you use Data Synchronisation Studio.
The example below connects to a SQL table with contact records that need to be imported into Salesforce and linked to an account. The account records have already been synchronised prior to this.&lt;/p&gt;
&lt;p&gt;Although we use a SQL table in this example you could use any of the other connectors as your source. This might be Active Directory, a SharePoint List, a CSV file or a Dynamics Entity to mention a few. Just select the connector you need, enter the required connection details and you're ready to go.&lt;/p&gt;
&lt;h3 id="connect"&gt;Connect to your Source Data&lt;/h3&gt;
&lt;p&gt;In this example we have a handful of contacts in a SQL table that we want to get into a Salesforce Contact object.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/datasync-contacts-preview.png" alt="Contact Sample Data" title="Contact Sample Data" /&gt;&lt;/p&gt;
&lt;p&gt;To do this we need to start by connecting our Source window to our SQL table. To do this click onto &lt;strong&gt;Connect Datasource&lt;/strong&gt; to open the connection window. Then navigate to &lt;strong&gt;SQL Database&lt;/strong&gt; &amp;gt; &lt;strong&gt;Microsoft SQL Server (SQL Client)&lt;/strong&gt;.&lt;/p&gt;
&lt;p&gt;Enter in the network name of your SQL Server, any credentials you might need to connect and set encryption or trusted certificate as required.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/sqlclient-connection.png" alt="SQl Connection" title="SQL Connection" /&gt;&lt;/p&gt;
&lt;p&gt;Click &lt;strong&gt;Connect &amp;amp; Create Library Connections&lt;/strong&gt; to save this database connection to the connection library. This only needs to be done once per database and will make future project setup easier.&lt;/p&gt;
&lt;p&gt;Select the database and table from the tree view to connect to, and if you are saving to the connection library another window will open where you need to enter a name in for the connection.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/sql-connection-selecttable.png" alt="Select Database" title="Select Database" /&gt;&lt;/p&gt;
&lt;p&gt;This will load the columns in your SQL table into the source window.&lt;/p&gt;
&lt;h3 id="salesforce"&gt;Connect to your Salesforce Object&lt;/h3&gt;
&lt;p&gt;To connect to Salesforce in Data Sync you need to have first &lt;a href="/docs/data-sync/connectors/salesforce/salesforce" target="_blank"&gt;configured the app registration in Salesforce&lt;/a&gt; so then you have all the details needed to connect via OAuth.&lt;/p&gt;
&lt;p&gt;You will need the redirect URL port number for your app registration which can be found in the connection window of Data Sync. To get to this click onto the target window and then go to &lt;strong&gt;Salesforce&lt;/strong&gt; &amp;gt; &lt;strong&gt;Salesforce Object&lt;/strong&gt;.&lt;/p&gt;
&lt;p&gt;Once you have configured the app in Salesforce you can now enter the &lt;strong&gt;Consumer Key&lt;/strong&gt; and &lt;strong&gt;Consumer Secret&lt;/strong&gt; into the connection window in Data Sync and click &lt;strong&gt;Authorize Connection&lt;/strong&gt; to validate the app details.&lt;/p&gt;
&lt;p&gt;If the authorisation is successful you will be able to select an object to connect to from the object name dropdown list.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/salesforce-connection-contact.png" alt="Salesforce Connection" title="Salesforce Connection" /&gt;&lt;/p&gt;
&lt;p&gt;Click &lt;strong&gt;Connect &amp;amp; Create Library Connection&lt;/strong&gt; to save the connection to the connection library. This only needs to be done once per site as you will be able to access the other objects from the connection library.&lt;/p&gt;
&lt;p&gt;If you have already saved your connection to the connection library then you can expand the connection and select the object you want to connect to.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/salesforce-connection-library-contact.png" alt="Salesforce Connection Library" title="Salesforce Connection Library" /&gt;&lt;/p&gt;
&lt;h3 id="mapping"&gt;Map the Source &amp;amp; Target Columns&lt;/h3&gt;
&lt;p&gt;You now need to configure the schema map so that the source columns are mapped to their corresponding column in Salesforce.
Make sure that the data types are correct and that you have selected a unique key column that can be used to identify each record.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/sql-salesforce-contact-mapping.png" alt="Mapping" title="Mapping" /&gt;&lt;/p&gt;
&lt;p&gt;If your source data doesn't have the Salesforce Account ID then you can do a lookup based on the internal account number.&lt;/p&gt;
&lt;h4 id="lookup-account-number"&gt;Lookup Account Number&lt;/h4&gt;
&lt;p&gt;In order to write to the account number column in salesforce you need to return the correct salesforce id for the account. If you have synchronised your internal account id's to the account number column within the salesforce account object then you can do a lookup to return the correct account id so that salesforce links the contact to the account.&lt;/p&gt;
&lt;p&gt;Just drag the account object from the connection library onto your account number column to create the lookup, and configure the connection to use the account number column to match the values.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/salesforce-accountnumberlookup.png" alt="Account Lookup" title="Account Lookup" /&gt;&lt;/p&gt;
&lt;p&gt;You can then map the id column returned by salesforce to the lookup account id column.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/salesforce-lookupaccount-mapping.png" alt="Lookup Mapping" title="Lookup Mapping" /&gt;&lt;/p&gt;
&lt;h3 id="compare"&gt;Preview the Results and Sync&lt;/h3&gt;
&lt;p&gt;Once the mapping is complete you can click &lt;strong&gt;Compare A &amp;gt; B&lt;/strong&gt; to preview the changes that need to be made.
Here you can preview additions, updates and delete actions.&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;Please note that deletes are disabled by default but will still show in the results. To enable deletes please set &lt;strong&gt;EnableDelete&lt;/strong&gt; to true in the target connection properties.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/data-sync-enabledelete.png" alt="Enable Delete" title="Enable Delete" /&gt;&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;Click onto each option to view the changes that will be applied to Salesforce. For updates the changes will be highlighted in yellow.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/sql-salesforce-contact-compare.png" alt="Updates" title="Updates" /&gt;&lt;/p&gt;
&lt;p&gt;To synchronise the results click onto the &lt;strong&gt;Synchronise&lt;/strong&gt; button and then &lt;strong&gt;Start&lt;/strong&gt; to begin the sync.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/sql-salesforce-sync.png" alt="Sync" title="Sync" /&gt;&lt;/p&gt;
&lt;p&gt;Your contact records will then be added to Salesforce and available to view.
Make sure to save your project so that you can use it again in the future.&lt;/p&gt;
&lt;h2 id="export"&gt;Exporting Data from Salesforce&lt;/h2&gt;
&lt;p&gt;If you need to get data out of Salesforce and integrate it with another business system then Data Sync makes this into another simple task.&lt;/p&gt;
&lt;p&gt;You can export the data previews to files such as XML, CSV, Excel and JSON for one off exports by using the buttons in the export window.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/datasync-export-preview-options.png" alt="Export Preview Options" title="Export Preview Options" /&gt;&lt;/p&gt;
&lt;p&gt;Alternatively you can create a new SQL table, CSV File or XML dataset for example from the tools menu, or you can connect to an existing system using any of the connectors available.&lt;/p&gt;
&lt;p&gt;In the example below we are setting up a project that will export the salesforce account records to an existing SQL table on a regular basis.&lt;/p&gt;
&lt;h3 id="connect-salesforce"&gt;Connect to your Salesforce Object&lt;/h3&gt;
&lt;p&gt;To connect to Salesforce in Data Sync you need to have first &lt;a href="/docs/data-sync/connectors/salesforce/salesforce" target="_blank"&gt;configured the app registration in Salesforce&lt;/a&gt; so then you have all the details needed to connect via OAuth.&lt;/p&gt;
&lt;p&gt;You will need the redirect URL port number for your app registration which can be found in the connection window of Data Sync. To get to this click onto the source window and go to &lt;strong&gt;Salesforce&lt;/strong&gt; &amp;gt; &lt;strong&gt;Salesforce Object&lt;/strong&gt;.&lt;/p&gt;
&lt;p&gt;Once you have configured the app in Salesforce you can enter the &lt;strong&gt;Consumer Key&lt;/strong&gt; and &lt;strong&gt;Consumer Secret&lt;/strong&gt; into the connection window in Data Sync and click &lt;strong&gt;Authorize Connection&lt;/strong&gt; to validate the app.&lt;/p&gt;
&lt;p&gt;If the authorisation is successful you will be able to select an object to connect to from the object name dropdown list.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/salesforce-connection-account.png" alt="Salesforce Connection" title="Salesforce Connection" /&gt;&lt;/p&gt;
&lt;p&gt;Click &lt;strong&gt;Connect &amp;amp; Create Library Connection&lt;/strong&gt; to save the connection to the connection library. This only needs to be done once per site as you will be able to access the other objects from the connection library.&lt;/p&gt;
&lt;p&gt;If you have already saved your connection to the connection library then you can expand the connection and select the object you want to connect to.&lt;/p&gt;
&lt;h3 id="script"&gt;Connect to your SQL table&lt;/h3&gt;
&lt;p&gt;To connect to a SQL table click onto &lt;strong&gt;Connect Datasource&lt;/strong&gt; in the target window to open the connection window. Then navigate to &lt;strong&gt;SQL Database&lt;/strong&gt; &amp;gt; &lt;strong&gt;Microsoft SQL Server (SQL Client)&lt;/strong&gt;.&lt;/p&gt;
&lt;p&gt;Enter in the network name of your SQL Server, any credentials you might need to connect and set encryption or trusted certificate as required.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/sqlclient-connection.png" alt="SQl Connection" title="SQL Connection" /&gt;&lt;/p&gt;
&lt;p&gt;Click &lt;strong&gt;Connect &amp;amp; Create Library Connections&lt;/strong&gt; to save this database connection to the connection library. This only needs to be done once per database and will make future project setup easier.&lt;/p&gt;
&lt;p&gt;Select the database and table from the tree view to connect to, and if you are saving to the connection library another window will open where you need to enter a name in for the connection.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/sql-connection-selecttable.png" alt="Select Database" title="Select Database" /&gt;&lt;/p&gt;
&lt;p&gt;This will load the columns in your SQL table into the target window.&lt;/p&gt;
&lt;h3 id="map-columns"&gt;Map the Source &amp;amp; Target Columns&lt;/h3&gt;
&lt;p&gt;You now need to configure the schema map so that the columns in Salesforce are mapped to their corresponding column in your SQL table.
Make sure that the data types are correct and that you have selected a unique key column that can be used to identify each record.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/salesforce-account-mapping.png" alt="Mapping" title="Mapping" /&gt;&lt;/p&gt;
&lt;h3 id="sync"&gt;Compare the Results and Sync&lt;/h3&gt;
&lt;p&gt;Once the mapping is complete you can click &lt;strong&gt;Compare A &amp;gt; B&lt;/strong&gt; to preview the changes that need to be made.
Here you can preview additions, updates and delete actions that need to be made.&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;Please note that deletes are disabled by default but will still show in the results. To enable deletes please set &lt;strong&gt;EnableDelete&lt;/strong&gt; to true in the target connection properties.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/data-sync-enabledelete.png" alt="Enable Delete" title="Enable Delete" /&gt;&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;Click onto each option to view the changes that will be applied to your SQL Table. For updates the changes will be highlighted in yellow.
In this example we have 80 records to add and 3 to update.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/sql-salesforce-account-compare.png" alt="Updates" title="Updates" /&gt;&lt;/p&gt;
&lt;p&gt;To synchronise the results click onto the &lt;strong&gt;Synchronise&lt;/strong&gt; button in the toolbar and then &lt;strong&gt;Start&lt;/strong&gt; to begin the sync.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/sql-salesforce-account-sync.png" alt="Sync" title="Sync" /&gt;&lt;/p&gt;
&lt;p&gt;Your contact records will then be added and available to view in your table.&lt;/p&gt;
&lt;p&gt;Make sure to save your project so that you can use it again in the future.&lt;/p&gt;
&lt;h2 id="misc"&gt;Additional Options&lt;/h2&gt;
Below you will find a couple of other topics such as troubleshooting, filtering the records and how to run the projects on a schedule.
&lt;h3 id="filter"&gt;Filtering the Results&lt;/h3&gt;
&lt;p&gt;When exporting results from Salesforce you can filter the results returned before you export, using either a SOQL Query or the filter box built into Data Sync.&lt;/p&gt;
&lt;h4 id="soql-query"&gt;SOQL Query&lt;/h4&gt;
&lt;p&gt;To use a SOQL query you need to have first connected to Salesforce and saved the connection to the connection library.
You can then either drag and drop or right click and connect to the SOQL Query connector within your Salesforce connection. To add the query to the project click onto the ellipsis in the connection properties window in the query field and hten enter in the statement.
You can import a query statement by using the &lt;strong&gt;Open From File&lt;/strong&gt; button to browse for the query.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/images/query-property-box.png" alt="Query Property Box" title="Query Property Box" /&gt;&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/images/import-query-salesforce.png" alt="Import Query" title="Import Query" /&gt;&lt;/p&gt;
&lt;p&gt;An example of a SOQL Query you could use could be, to select all records in the contact object that have a first name of &amp;quot;Dave&amp;quot;:&lt;/p&gt;
&lt;div class="lang-SQL editor-colors"&gt;&lt;div style="color:Black;background-color:White;"&gt;&lt;pre&gt;
&lt;span style="color:Blue;"&gt;SELECT&lt;/span&gt; Id, FirstName
&lt;span style="color:Blue;"&gt;FROM&lt;/span&gt; Contact
&lt;span style="color:Blue;"&gt;WHERE&lt;/span&gt; FirstName = &lt;span style="color:#A31515;"&gt;&amp;quot;Dave&amp;quot;&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;h4 id="filter-box"&gt;Filter Box&lt;/h4&gt;
&lt;p&gt;To use the filter box built into Data Sync, start by connecting to Salesforce.
Then enter in a function to filter your records. This function needs to be in a C# friendly format i.e. no spaces in the column names and no special characters.&lt;/p&gt;
&lt;p&gt;An example to filter the results for a specific company is: &lt;code&gt;Name == &amp;quot;MyCompany&amp;quot;&lt;/code&gt;&lt;/p&gt;
&lt;p&gt;The expression needs to return &lt;strong&gt;true&lt;/strong&gt; in order to return any results. So for the example above if there is not an exact match for &lt;code&gt;MyCompany&lt;/code&gt; in the &lt;strong&gt;Name&lt;/strong&gt; column in Salesforce then no results will be returned.
If &lt;code&gt;MyCompany&lt;/code&gt; exists then the record will be returned.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/salesforce-account-filterresults.png" alt="Filter" title="Filter" /&gt;&lt;/p&gt;
&lt;p&gt;To preview the results click onto the &lt;strong&gt;Preview A&lt;/strong&gt; button in the schema map window.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/datasync-schema-map-previewa.png" alt="Preview Filtered Results" title="Preview Filtered Results" /&gt;&lt;/p&gt;
&lt;h3 id="schedule"&gt;Automate and Schedule&lt;/h3&gt;
If you want these projects to run on a regular basis then you can automate them and schedule them to run using either the Run Tool &amp; Windows Task Scheduler or Ouvvi Automation Server.
&lt;p&gt;The Run Tool will enable you to collect together multiple projects to run in a sequence and then schedule them to run at a regular time or interval using Windows Task Scheduler.
The Run Tool can be accessed either through the start menu or through the Tools menu in Data Sync.&lt;/p&gt;
&lt;p&gt;There a multiple step types available so that you can build out your integration project further. For example you can add an email report step to send an email every time the project runs or if there is a failure.
You will find more information on &lt;a href="/docs/data-sync/run-tool/intro"&gt;how to use the Run Tool here&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;If you want a fully documented integration manager and scheduling system then Ouvvi will be the tool to use.&lt;/p&gt;
&lt;p&gt;Ouvvi enables you to bring together multiple projects, steps and even Run Tool projects into the workspace and then schedule these to run using either time based or event based triggers.
The whole environment can be documented at a click of a button and you can add additional description to each of your projects and steps to help other users understand their function.&lt;/p&gt;
&lt;p&gt;You can find more information on how to &lt;a href="/docs/ouvvi/training/tour"&gt;get started with Ouvvi&lt;/a&gt; in our training pages.&lt;/p&gt;
&lt;h3 id="troubleshoot"&gt;Troubleshooting&lt;/h3&gt;
&lt;h4 id="connection-erroring-a-day-later"&gt;Connection Erroring a day later&lt;/h4&gt;
&lt;p&gt;If you find the connection errors on the second day that the project runs then it is likely you didn't save it to the connection library.
The connection library handles getting the refresh token for you whenever it is needed.&lt;/p&gt;
&lt;p&gt;Alternatively it might be that you didn't add the correct scope when creating the app in Salesforce. Please take a look at your app registration in Salesforce to ensure that the &lt;strong&gt;Perform requests on your behalf at any time (refresh_token, offline_access)&lt;/strong&gt; scope has been added.&lt;/p&gt;
&lt;h4 id="what-api-and-api-version-does-the-connector-use"&gt;What API and API version does the connector use?&lt;/h4&gt;
&lt;p&gt;The Salesforce connector uses the REST API and binds to the latest version available, so you remain ahead of any deprecations.&lt;/p&gt;
&lt;p&gt;If you have any questions on how to use Data Sync, the Run Tool or Ouvvi, or need more help connecting to Salesforce please reach out to us at support@simego.com.&lt;/p&gt;
</description>
      <source url="http://www.simego.com/blog">Team Blog</source>
      <pubDate>Wed, 30 Mar 2022 10:00:00 +0000</pubDate>
    </item>
    <item>
      <link>http://www.simego.com/blog/dynamics-navision-synchronisations</link>
      <author>info@simego.com (Rebecca Allen)</author>
      <title>Synchronising Data with Dynamics Navision and OData</title>
      <description>&lt;p&gt;With Data Sync you can import and export data to and from your Navision objects/cards.&lt;/p&gt;
&lt;p&gt;The following article covers a couple of considerations you need when planning your Navision integration, we go through using Ouvvi to manage and schedule the whole project, and how to configure an example Data Sync step to get data from a SQL table into Dynamics Navision.&lt;/p&gt;
&lt;p&gt;Although we use the example of a SQL table in this article, you can use any of the available connectors to import and export data from Dynamics Nav. If there is not currently a connector for your system then you can always &lt;a href=""&gt;build a custom connector&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;Here we cover how to connect using OData V4 however check out our other blog if you are looking to connect via &lt;a href="reading-data-from-dynamics-nav-web-service-connector"&gt;SOAP Web Services&lt;/a&gt;.&lt;/p&gt;
&lt;div class="text-center"&gt;&lt;img src="https://images.simego.com/blog/navision-integration.png" title="Navision Integration" alt="Navision Integration"/&gt;&lt;/div&gt;
&lt;section class="section-tiny alternate-color"&gt;
&lt;div class="container"&gt;
&lt;h3&gt;Contents&lt;/h3&gt;
&lt;ol&gt;
                    &lt;li&gt;
                        &lt;a href="#requirements"&gt;Requirements&lt;/a&gt;
                    &lt;/li&gt;
                    &lt;li&gt;
                        &lt;a href="#import"&gt;Considerations when Importing into Navision&lt;/a&gt;
                    &lt;/li&gt;
                        &lt;li&gt;
                            &lt;a href="#ouvvi"&gt;Ouvvi Configuration&lt;/h3&gt;
                        &lt;/li&gt;
                        &lt;li&gt;
                            &lt;a href="#connect"&gt;Connect to your Source Data&lt;/a&gt;
                        &lt;/li&gt;
                        &lt;li&gt;
                            &lt;a href="#navision"&gt;Connect to Navision&lt;/a&gt;
                        &lt;/li&gt;
                        &lt;li&gt;
                            &lt;a href="#mapping"&gt;Map the Source &amp;amp; Target Columns&lt;/a&gt;
                        &lt;/li&gt;
                        &lt;li&gt;
                            &lt;a href="#compare"&gt;Preview the Results and Sync&lt;/a&gt;
                        &lt;/li&gt;
                    &lt;li&gt;
                        &lt;a href="#schedule"&gt;Schedule&lt;/a&gt;
                    &lt;/li&gt;
                    &lt;li&gt;
                        &lt;a href="#export"&gt;Exporting Data from Navision&lt;/a&gt;
                    &lt;/li&gt;                    
                    &lt;ul&gt;
                        &lt;li&gt;
                            &lt;a href="#connect-navision"&gt;Connect to Navision&lt;/a&gt;
                        &lt;/li&gt;
                        &lt;li&gt;
                            &lt;a href="#connect-sql"&gt;Connect to your SQL Table&lt;/a&gt;
                        &lt;/li&gt;
                        &lt;li&gt;
                            &lt;a href="#map-columns"&gt;Map the Source &amp;amp; Target Columns&lt;/a&gt;
                        &lt;/li&gt;
                        &lt;li&gt;
                            &lt;a href="#sync"&gt;Preview the Results and Sync&lt;/a&gt;
                        &lt;/li&gt;
                    &lt;/ul&gt;
                    &lt;li&gt;
                        &lt;a href="#misc"&gt;Miscellaneous&lt;/a&gt;
                    &lt;/li&gt;
                    &lt;ul&gt;
                        &lt;li&gt;
                            &lt;a href="#filter"&gt;Filtering the Results&lt;/a&gt;
                        &lt;/li&gt;
                        &lt;li&gt;
                            &lt;a href="#troubleshoot"&gt;Troubleshooting&lt;/a&gt;
                        &lt;/li&gt;
                        &lt;li&gt;
                            &lt;a href="#cache"&gt;Clearing the Cache in Data Sync&lt;/a&gt;
                        &lt;/li&gt;
                    &lt;/ul&gt;
                &lt;/ol&gt;
&lt;/div&gt;
&lt;/section&gt;
&lt;h2 id="requirements"&gt;Requirements&lt;/h2&gt;
&lt;p&gt;Before getting started you need to ensure you have the following:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Windows 10 or Windows Server&lt;/li&gt;
&lt;li&gt;Downloaded &amp;amp; Installed Data Synchronisation Studio&lt;/li&gt;
&lt;li&gt;Installed Ouvvi Automation Server&lt;/li&gt;
&lt;li&gt;Access to Dynamics Navision&lt;/li&gt;
&lt;li&gt;Access to a SQL table&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;If you do not have &lt;strong&gt;Data Synchronisation Studio&lt;/strong&gt; you can get a &lt;a href="/install/data-synchronisation-studio"&gt;free evaluation edition&lt;/a&gt;.
To test Ouvvi during a trial please contact us to discuss upgrading your evaluation license.&lt;/p&gt;
&lt;h2 id="import"&gt;Importing Data into Navision&lt;/h2&gt;
&lt;p&gt;You can quickly and easily synchronise your business data into Dynamics Nav when you use Data Synchronisation Studio.&lt;/p&gt;
&lt;p&gt;You need to consider which columns you want to be updating within the cards and if those columns relational fields that lookup their values in a different entity.
For example, invoice needs the customer to already exist in the customer entity. If the value doesn't exist then an error will be thrown &lt;code&gt;The remote server returned an error: (400) Bad Request&lt;/code&gt;.
So the customer entity needs to be updated before the invoice entity.&lt;/p&gt;
&lt;p&gt;To get around this type of issue you need to look at the structure of your Navision and plan your integration accordingly.
This is where Ouvvi becomes invaluable as you can contain each Data Sync project as a step, add descriptions to the overall project and individually on each step, and execute the whole process in a sequence.
This ensures cards are updated in the correct order to prevent errors.&lt;/p&gt;
&lt;p&gt;We came across a useful site for finding out the relationships between tables in Nav, if you want to take a look you can find it at this link: &lt;a href="https://dynamicsdocs.com/nav/2018/w1/" target="_blank"&gt;https://dynamicsdocs.com/nav/2018/w1/&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;Below we cover creating your project and steps within Ouvvi and how to configure an example Data Sync step to connect to update data in Dynamics Navision.&lt;/p&gt;
&lt;p&gt;Although we use a SQL table in this example you can use any of the other connectors as your source. This might be Active Directory, a SharePoint List, a CSV file or a Dynamics Entity to mention a few. Just select the connector you need, enter the required connection details and you're ready to go.&lt;/p&gt;
&lt;h2 id="ouvvi"&gt;Ouvvi Configuration&lt;/h2&gt;
&lt;p&gt;We need to start by creating our Ouvvi project to hold each Data Sync step in the integration.
To do this open Ouvvi and go to Projects &amp;gt; All Projects &amp;gt; New. Enter in a Name for your project and click &lt;strong&gt;Save&lt;/strong&gt; to continue.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/ouvvi-add-new-project.png" alt="Create New Ouvvi Project" title="Create New Ouvvi Project" /&gt;&lt;/p&gt;
&lt;p&gt;You then need to add a Data Sync step.
For this integration project there are going to be multiple Data Sync steps that will need to be configured to connect to the source data and the relevant Navision entity.&lt;/p&gt;
&lt;p&gt;For the purpose of this article we will only focus on the configuring of one step, but the process should be the same for each step.&lt;/p&gt;
&lt;p&gt;To add a Data Sync step go to &lt;strong&gt;Add Step&lt;/strong&gt; &amp;gt; &lt;strong&gt;Data Sync Project&lt;/strong&gt; and then enter in a name for the project and click &lt;strong&gt;Save&lt;/strong&gt;.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/ouvvi-add-datatsync-step.png" alt="Add Data Sync Step" title="Add Data Sync Step" /&gt;&lt;/p&gt;
&lt;p&gt;Then open the project by clicking &lt;strong&gt;Open Project&lt;/strong&gt;.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/ouvvi-openproj-navisioncustomers.png" alt="Open Data Sync" title="Open Data Sync" /&gt;&lt;/p&gt;
&lt;p&gt;When Data Sync has downloaded from Ouvvi and you open the file, you should find that it shows as connected to Ouvvi.
You can check this in four locations:&lt;br /&gt;
1- The title bar&lt;br /&gt;
2- The connection library&lt;br /&gt;
3- The output window&lt;br /&gt;
4- The bottom right of the window&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/ouvvi-connected-datasync.png" alt="Connected to Ouvvi" title="Connected to Ouvvi" /&gt;&lt;/p&gt;
&lt;p&gt;You can now configure the project within Data Sync.&lt;/p&gt;
&lt;h2 id="connect"&gt;Connect to your Source Data&lt;/h2&gt;
&lt;p&gt;In this example we will be configuring the project to import customers from a SQL table into the Navision Customers object.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/datasync-customers-preview.png" alt="Customers Sample Data" title="Customers Sample Data" /&gt;&lt;/p&gt;
&lt;p&gt;To do this we need to start by connecting our Source window to our SQL table. To do this click onto &lt;strong&gt;Connect Datasource&lt;/strong&gt; to open the connection window. Then navigate to &lt;strong&gt;SQL Database&lt;/strong&gt; &amp;gt; &lt;strong&gt;Microsoft SQL Server (SQL Client)&lt;/strong&gt;.&lt;/p&gt;
&lt;p&gt;Enter in the network name of your SQL Server, any credentials you might need to connect and set encryption or trusted certificate as required.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/sqlclient-connection.png" alt="SQl Connection" title="SQL Connection" /&gt;&lt;/p&gt;
&lt;p&gt;Click &lt;strong&gt;Connect &amp;amp; Create Library Connections&lt;/strong&gt; to save this database connection to the connection library. This only needs to be done once per database and will make future project setup easier.&lt;/p&gt;
&lt;p&gt;Select the database and table from the tree view to connect to, and if you are saving to the connection library another window will open where you need to enter a name in for the connection.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/sql-connection-selecttable.png" alt="Select Database" title="Select Database" /&gt;&lt;/p&gt;
&lt;p&gt;This will load the columns in your SQL table into the source window.&lt;/p&gt;
&lt;h2 id="navision"&gt;Connect to Navision&lt;/h2&gt;
&lt;p&gt;When connecting to Navision you need to have first &lt;a href="/docs/data-sync/connectors/odata/navision" target="_blank"&gt;published each entity you want to connect to&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;You will need the OData V4 endpoint URL which will look something like: &lt;code&gt;http://nav17:7048/DynamicsNAV110/ODataV4/Company('CRONUS%20UK%20Ltd.')/Customers&lt;/code&gt; and you need to edit this to remove the entity from the end of the URL.&lt;/p&gt;
&lt;p&gt;Your URL should now look like &lt;code&gt;http://nav17:7048/DynamicsNAV110/ODataV4/Company('CRONUS%20UK%20Ltd.')/&lt;/code&gt;. Enter this into &lt;strong&gt;ServiceURL&lt;/strong&gt; field.&lt;/p&gt;
&lt;p&gt;Make sure to enter any credentials into the relevant credentials field. i.e. Windows credentials to access your Navision Server need to be entered into the Windows field. Leaving this blank will use the current user credentials.
If the project is being run in Ouvvi, this will be the service account.&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;Be aware that if the account does not have permission to access the Nav server then the connection will fail and error.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;Once these details have been entered select the entity/card to connect to from the dropdown. In this example we select &lt;strong&gt;Customers&lt;/strong&gt; as we are exporting the Customer Card in Navision.&lt;/p&gt;
&lt;p&gt;Click &lt;strong&gt;Connect &amp;amp; Create Library Connection&lt;/strong&gt; to save the connection to the connection library. This only needs to be done once per site as you will be able to access the other entities/cards from the connection library.&lt;/p&gt;
&lt;p&gt;As the project has been opened from Ouvvi, the connection will be stored in the Ouvvi connection library.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/navision-connection-customers.png" alt="Navision Customers Connection" title="Navision Customers Connection" /&gt;&lt;/p&gt;
&lt;p&gt;If you have already saved your connection to the connection library then you can expand the connection and select the object you want to connect to.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/navision-connectionlibrary.png" alt="Navision Connection Library" title="Navision Connection Library" /&gt;&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;NB. If you publish more Nav entities after you have connected you may need to delete the cache file and refresh your connection. You can find the cache folder by going to Tool&amp;gt; Open Schema Cache Folder, then delete the cache file for your Navision connection.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;h2 id="mapping"&gt;Map the Source &amp;amp; Target Columns&lt;/h2&gt;
&lt;p&gt;You now need to configure the schema map so that the source columns are mapped to their corresponding column in Navision.&lt;/p&gt;
&lt;p&gt;Some nav objects will have multiple key columns so be sure to map these where required.&lt;/p&gt;
&lt;p&gt;Make sure that the data types are correct and that you have selected a unique key column that can be used to identify each record.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/navision-customers-mapping.png" alt="Customer Mapping" title="Customer Mapping" /&gt;&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;Navision can be tricky to integrate with so the initial project setup may have a bit of trial and error. You may find that some columns are not possible to write to or they may be expecting the data to be presented in a specific format.
To diagnose try removing columns you suspect could be causing the error and add them back one at a time. You can also preview the records in Nav using the Preview B button to see how the data is being returned.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;h2 id="compare"&gt;Preview the Results and Test&lt;/h2&gt;
&lt;p&gt;Once the mapping is complete you can click &lt;strong&gt;Compare A &amp;gt; B&lt;/strong&gt; to preview the changes that need to be made.
Here you can preview additions, updates and delete actions that need to be made. In this example there are 90 records to add and 1 to update.&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;Please note that deletes are disabled by default but will still show in the results. To enable deletes please set &lt;strong&gt;EnableDelete&lt;/strong&gt; to true in the target connection properties.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/data-sync-enabledelete.png" alt="Enable Delete" title="Enable Delete" /&gt;&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;Click onto each option will enable you to view the changes. For updates the changes will be highlighted in yellow.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/navision-customers-compareresults.png" alt="Updates" title="Updates" /&gt;&lt;/p&gt;
&lt;p&gt;You can either wait to synchronise everything in sequence or you can run the synchronisation now.
We do recommend running a test to make sure there are no issues as Navsion can be temperamental to write data to.&lt;/p&gt;
&lt;p&gt;To test a few records start by deselecting the update checkbox and click onto the adds, then click &lt;strong&gt;Clear ALL&lt;/strong&gt; to clear the checkboxes and select one or two records to add.
Then click Synchronise and Start to begin the sync.&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;Be aware that if you are testing within the Cronus environment there are data restrictions. For example you can only add dates that are in Nov, Dec, Jan or Feb. Anything outside of this will cause an error to be thrown.
In a fully licensed Nav environment you will not have this issue.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;Once you are confident the columns are mapped correctly and Navision will allow you to write to the columns you have selected you can save the project and return to Ouvvi.&lt;/p&gt;
&lt;p&gt;You can then continue configuring the other projects, add a trigger to schedule it or manually run the Ouvvi project with the &lt;strong&gt;Start Project&lt;/strong&gt; button.&lt;/p&gt;
&lt;p&gt;Your Ouvvi project might look similar to the below image once you have added all of your required steps.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/ouvvi-navisionintegration-project.png" alt="Ouvvi Overview" title="Ouvvi Overview" /&gt;&lt;/p&gt;
&lt;h2 id="schedule"&gt;Schedule&lt;/h2&gt;
&lt;p&gt;You can now add a trigger to your project to run it on a schedule, for this example we are using the start of day trigger and the end of day trigger. This will run the project at the times configured in the Ouvvi Settings.&lt;/p&gt;
&lt;p&gt;By default these are 8am and 6pm but you can always change them to suit your needs. To do this go to Settings &amp;gt; System Settings &amp;gt; Edit and then change the start and end times.&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;Please be aware of any time zone settings and if your Navision or Server is using a different timezone eg. one might be in UTC and the other in local. This can make the trigger look like they are starting at the wrong time but are actually just running in the wrong time zone.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/ouvvi-startofday-trigger-navision.png" alt="Add Start of Day Trigger" title="Add Start of Day Trigger" /&gt;&lt;/p&gt;
&lt;p&gt;Please see our training page &lt;a href="/docs/ouvvi/training/triggers-add"&gt;to learn how to create a new trigger&lt;/a&gt;.&lt;/p&gt;
&lt;h2 id="export"&gt;Exporting Data from Dynamics Navision&lt;/h2&gt;
&lt;p&gt;If you need to get data out of Navision and integrate it with another business system then Data Sync makes this simple.&lt;/p&gt;
&lt;p&gt;You can export the data previews to files such as XML, CSV, Excel and JSON for one off exports by using the buttons in the preview window.&lt;/p&gt;
&lt;p&gt;Alternately you can create a new SQL table, CSV File or XML dataset for example from the tools menu, or you can connect to an existing system using any of the connectors available.&lt;/p&gt;
&lt;p&gt;In the example below we are setting up a project that will export the Navision item card to an existing SQL table on a regular basis.&lt;/p&gt;
&lt;h3 id="connect-navision"&gt;Connect to your Navision Object&lt;/h3&gt;
&lt;p&gt;To connect to Dynamics Navision in Data Sync you need to have first published the card in Navision so then you access the records via the OData V4 API.&lt;/p&gt;
&lt;p&gt;In our documentation we cover &lt;a href="/docs/data-sync/connectors/odata/navision" target="_blank"&gt;how to publish entities in Navision.&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;You will need the OData V4 endpoint URL which will look something like: &lt;code&gt;http://nav17:7048/DynamicsNAV110/ODataV4/Company('CRONUS%20UK%20Ltd.')/Lists&lt;/code&gt; and you need to edit this to remove the entity from the end of the URL.&lt;/p&gt;
&lt;p&gt;Your URL should now look like &lt;code&gt;http://nav17:7048/DynamicsNAV110/ODataV4/Company('CRONUS%20UK%20Ltd.')/&lt;/code&gt;. Enter this into the &lt;strong&gt;ServiceURL&lt;/strong&gt; field.&lt;/p&gt;
&lt;p&gt;Make sure to enter any credentials into the relevant credentials field. i.e. Windows credentials to access your Navision Server need to be entered into the Windows field. Leaving this blank will use the current user crednetials to access. If the project is being run in Ouvvi, this will be the service account.
Be aware that if the account does not have permission to access the Nav server then the connection will fail and error.&lt;/p&gt;
&lt;p&gt;Once these details have been entered select the entity/card to connect to from the dropdown. In this example we select &lt;strong&gt;Items&lt;/strong&gt; as we are exporting the items from Navision.&lt;/p&gt;
&lt;p&gt;Click &lt;strong&gt;Connect &amp;amp; Create Library Connection&lt;/strong&gt; to save the connection to the connection library. This only needs to be done once per site as you will be able to access the other objects from the connection library.&lt;/p&gt;
&lt;p&gt;If you have opened the project from Ouvvi then the connection will be stored in the Ouvvi connection library.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/navision-connection-items.png" alt="Navision Items Connection" title="Navision Items Connection" /&gt;&lt;/p&gt;
&lt;p&gt;If you have already saved your connection to the connection library then you can expand the connection and select the entity you want to connect to.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/navision-connectionlibrary.png" alt="OData Connection Library" title="OData Connection Library" /&gt;&lt;/p&gt;
&lt;h3 id="script"&gt;Connect to your SQL table&lt;/h3&gt;
&lt;p&gt;To connect to a SQL table click onto &lt;strong&gt;Connect Datasource&lt;/strong&gt; in the target window to open the connection window. Then navigate to &lt;strong&gt;SQL Database&lt;/strong&gt; &amp;gt; &lt;strong&gt;Microsoft SQL Server (SQL Client)&lt;/strong&gt;.&lt;/p&gt;
&lt;p&gt;Enter in the network name of your SQL Server, any credentials you might need to connect and set encryption or trusted certificate as required.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/sqlclient-connection.png" alt="SQl Connection" title="SQL Connection" /&gt;&lt;/p&gt;
&lt;p&gt;Click &lt;strong&gt;Connect &amp;amp; Create Library Connections&lt;/strong&gt; to save this database connection to the connection library. This only needs to be done once per database and will make future project setup easier.&lt;/p&gt;
&lt;p&gt;Select the database and table from the tree view to connect to, and if you are saving to the connection library another window will open where you need to enter a name in for the connection.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/sql-connection-selecttable.png" alt="Select Database" title="Select Database" /&gt;&lt;/p&gt;
&lt;p&gt;This will load the columns in your SQL table into the target window.&lt;/p&gt;
&lt;h3 id="map-columns"&gt;Map the Source &amp;amp; Target Columns&lt;/h3&gt;
&lt;p&gt;You now need to configure the schema map so that the columns in Navision are mapped to their corresponding column in your SQL table.
Make sure that the data types are correct and that you have selected a unique key column that can be used to identify each record.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/navision-itemsexport-mapping.png" alt="Mapping" title="Mapping" /&gt;&lt;/p&gt;
&lt;h3 id="sync"&gt;Compare the Results and Sync&lt;/h3&gt;
&lt;p&gt;Once the mapping is complete you can click &lt;strong&gt;Compare A &amp;gt; B&lt;/strong&gt; to preview the changes that need to be made.
Here you can preview additions, updates and delete actions that need to be made.&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;Please note that deletes are disabled by default but will still show in the results. To enable deletes please set &lt;strong&gt;EnableDelete&lt;/strong&gt; to true in the target connection properties.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/data-sync-enabledelete.png" alt="Enable Delete" title="Enable Delete" /&gt;&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;Click onto each option to view the changes that will be applied to your SQL Table. For updates the changes will be highlighted in yellow.
In this example we have 226 records to add.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/navision-items-export-compareresults.png" alt="Records to Add" title="Records to Add" /&gt;&lt;/p&gt;
&lt;p&gt;To synchronise the results click onto the &lt;strong&gt;Synchronise&lt;/strong&gt; button in the toolbar and then &lt;strong&gt;Start&lt;/strong&gt; to begin the sync.
Your items will then be added to your SQL table and available to use.&lt;/p&gt;
&lt;h2 id="misc"&gt;Miscellaneous&lt;/h2&gt;
&lt;p&gt;Below you will find a few additional points on filtering the results, a few troubleshooting tips if your project is throwing an error, and how to clear the cache if you make changes to the connection.&lt;/p&gt;
&lt;h3 id="filter"&gt;Filtering the Results&lt;/h3&gt;
You can filter the results before exporting by using the filter box built into the source window.
&lt;p&gt;Just enter in a C# Expression that returns true to only return a specific set of results. For example we could filter the items list to return only items of a specific type using the following expression:&lt;/p&gt;
&lt;p&gt;&lt;code&gt;Type == &amp;quot;Inventory&amp;quot;&lt;/code&gt;&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/navision-filter-datasource.png" alt="Filter Expression" title="Filter Expression" /&gt;&lt;/p&gt;
&lt;p&gt;You can then preview the data using the preview A button in the schema map before synchronising to check the correct results are being returned.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/datasync-schema-map-previewa.png" alt="Preview Filtered Results" title="Preview Filtered Results" /&gt;&lt;/p&gt;
&lt;h3 id="troubleshoot"&gt;Troubleshooting&lt;/h3&gt;
&lt;h4 id="method-exception-failure"&gt;Method Exception Failure&lt;/h4&gt;
&lt;p&gt;If you are getting a Method Exception Failure then it is most likely down to not publishing the correct object. For example for Items you need to publish and connect to the Items card.&lt;/p&gt;
&lt;h4 id="bad-request-error"&gt;Bad Request Error&lt;/h4&gt;
&lt;p&gt;If you keep getting &lt;strong&gt;Bad request&lt;/strong&gt; as an error then you need to take a look at what is being written to as there are a couple of reasons for this error.&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;There is a field that cannot be written to included in the schema map&lt;/li&gt;
&lt;li&gt;A field mapped in the schema map throws an action in Navision which cannot be handled on the API&lt;/li&gt;
&lt;li&gt;There is a required field missing from the schema map so the record cannot be created.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;One way to diagnose which field is throwing the error is to remove fields and add them back one at a time, synchronising one record at a time.&lt;/p&gt;
&lt;p&gt;Another way to work out what is wrong is to create a simple record in Nav and see what data is required in the UI. This will help you work out what is needed when writing to Navision.&lt;/p&gt;
&lt;p&gt;You can also enable trace in the connection properties to see the data being sent in the output window.&lt;/p&gt;
&lt;h3 id="cache"&gt;Clearing the Cache in Data Sync&lt;/h3&gt;
&lt;p&gt;If you have published a new entity or made a change to the connection, you will need to clear the cache file before the new changes will be visible.&lt;/p&gt;
&lt;p&gt;To remove the cache file go to Tools &amp;gt; Open Cache Folder and then delete the Navision file. Alternatively the cache folder can be found at &lt;code&gt;C:\ProgramData\Simego\DataSyncStudio30\Cache&lt;/code&gt;.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/navision-cache-file.png" alt="Navision Cache File" title="Navision Cache File" /&gt;&lt;/p&gt;
&lt;p&gt;You can then go back to Data Sync and try connecting to Navision again. Your new entity should now be visible in the list.&lt;/p&gt;
&lt;p&gt;If you have any questions please reach out to us at support@simego.com.&lt;/p&gt;
</description>
      <source url="http://www.simego.com/blog">Team Blog</source>
      <pubDate>Tue, 05 Apr 2022 10:00:00 +0000</pubDate>
    </item>
    <item>
      <link>http://www.simego.com/blog/scheduled-export-import-for-dynamics-365</link>
      <author>info@simego.com (Rebecca Allen)</author>
      <title>Scheduled Import and Export for Dynamics 365</title>
      <description>&lt;p&gt;When integrating with Dynamics 365 (aka. CRM, dataverse or CE) you want to be able to set your projects up once and then be able to repeat them at regular intervals.
You may have other systems relying on Data from Dynamics 365 or need to update Dynamics 365 with data from another source.&lt;/p&gt;
&lt;p&gt;For example you might have a SQL Database where account records are updated and these need feeding into Dynamics. Alternatively you might need to get the contact records, that are updated regularly by the sales team, into another system to ensure it is kept up to date.&lt;/p&gt;
&lt;p&gt;For the following example we are going to use Ouvvi to schedule, manage and automate a series of projects that update Dynamics on a regular basis.
We cover how to configure the projects so that you can link two entities together, i.e. account and contact records.&lt;/p&gt;
&lt;p&gt;We will also cover configuring projects to export data from Dynamics into a SQL table, XML file and Excel file and having these run at the start of the day.&lt;/p&gt;
&lt;div class="text-center"&gt;&lt;img src="https://images.simego.com/blog/dynamics-integration.png" title="Dynamics Integration" alt="Dynamics Integration"/&gt;&lt;/div&gt;
&lt;section class="section-tiny alternate-color"&gt;
&lt;div class="container"&gt;
&lt;h3&gt;Contents&lt;/h3&gt;
&lt;ol&gt;
                    &lt;li&gt;
                        &lt;a href="#requirements"&gt;Requirements&lt;/a&gt;
                    &lt;/li&gt;
                    &lt;li&gt;
                        &lt;a href="#import"&gt;Considerations when Importing into Dynamics&lt;/a&gt;
                    &lt;/li&gt;
                        &lt;li&gt;
                            &lt;a href="#ouvvi"&gt;Ouvvi Configuration&lt;/h3&gt;
                        &lt;/li&gt;
                        &lt;li&gt;
                            &lt;a href="#connect"&gt;Connect to your Source Data&lt;/a&gt;
                        &lt;/li&gt;
                        &lt;li&gt;
                            &lt;a href="#dynamics"&gt;Connect to Dynamics&lt;/a&gt;
                        &lt;/li&gt;
                        &lt;li&gt;
                            &lt;a href="#lookup"&gt;Create the Lookup to Account&lt;/a&gt;
                        &lt;/li&gt;
                        &lt;li&gt;
                            &lt;a href="#mapping"&gt;Map the Source &amp;amp; Target Columns&lt;/a&gt;
                        &lt;/li&gt;
                        &lt;li&gt;
                            &lt;a href="#compare"&gt;Preview the Results and Sync&lt;/a&gt;
                        &lt;/li&gt;
                    &lt;li&gt;
                        &lt;a href="#schedule"&gt;Schedule&lt;/a&gt;
                    &lt;/li&gt;
                    &lt;li&gt;
                        &lt;a href="#export"&gt;Exporting Data from Dynamics&lt;/a&gt;
                    &lt;/li&gt;                    
                    &lt;ul&gt;
                        &lt;li&gt;
                            &lt;a href="#connect-dynamics"&gt;Connect to Dynamics&lt;/a&gt;
                        &lt;/li&gt;
                    &lt;/ul&gt;
                    &lt;li&gt;
                        &lt;a href="#exportoptions"&gt;Export Options&lt;/a&gt;
                    &lt;/li&gt;
                    &lt;ul&gt;    
                        &lt;li&gt;
                            &lt;a href="#single"&gt;Single Export to File&lt;/a&gt;
                        &lt;/li&gt;
                        &lt;li&gt;
                            &lt;a href="#new"&gt;Export to a New Data Source&lt;/a&gt;
                        &lt;/li&gt;
                        &lt;li&gt;
                            &lt;a href="#existing"&gt;Export to an Existing Data Source&lt;/a&gt;
                        &lt;/li&gt;
                    &lt;/ul&gt;
                    &lt;li&gt;
                        &lt;a href="#troubleshoot"&gt;Troubleshooting&lt;/a&gt;
                    &lt;/li&gt;
                &lt;/ol&gt;
&lt;/div&gt;
&lt;/section&gt;
&lt;h2 id="requirements"&gt;Requirements&lt;/h2&gt;
&lt;p&gt;Before getting started you need to ensure you have the following:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Windows 10 or Windows Server&lt;/li&gt;
&lt;li&gt;Downloaded &amp;amp; Installed Data Synchronisation Studio&lt;/li&gt;
&lt;li&gt;Installed Ouvvi Automation Server&lt;/li&gt;
&lt;li&gt;Access to Dynamics 365&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;If you do not have &lt;strong&gt;Data Synchronisation Studio&lt;/strong&gt; you can get a &lt;a href="/install/data-synchronisation-studio"&gt;free evaluation edition&lt;/a&gt;.
To test Ouvvi during a trial please contact us to discuss upgrading your evaluation license.&lt;/p&gt;
&lt;h2 id="import"&gt;Considerations when Importing Data into Dynamics&lt;/h2&gt;
You can quickly and easily synchronise your business data into Dynamics 365 (CRM / CE/ Dataverse) when you use Data Synchronisation Studio.
&lt;p&gt;You need to consider which columns you want to be updating within the entity and if those columns are relational fields that lookup their values in a different entity.&lt;/p&gt;
&lt;p&gt;For example, contact needs the account to already exist in the contact entity. If the value doesn't exist then an error will be thrown &lt;code&gt;The remote server returned an error: (400) Bad Request&lt;/code&gt;.
So the account entity needs to be updated before the contact entity.&lt;/p&gt;
&lt;p&gt;To get around this type of issue you need to look at the structure of your Dynamics 365 site and plan your integration accordingly.&lt;/p&gt;
&lt;p&gt;This is where Ouvvi is invaluable as you can contain each Data Sync project as a step, add descriptions to the overall project and individually on each step, and execute the whole process in a sequence.
This ensures entities are updated in the correct order to prevent errors.&lt;/p&gt;
&lt;p&gt;Below we cover creating your project and steps within Ouvvi and how to configure an example Data Sync step to connect to update data in Dynamics 365.&lt;/p&gt;
&lt;p&gt;Although we use a SQL table in this example you can use any of the other connectors as your source. This might be Active Directory, a SharePoint List, a CSV file or a Dynamics Entity to mention a few. Just select the connector you need, enter the required connection details and you're ready to go.&lt;/p&gt;
&lt;h2 id="ouvvi"&gt;Ouvvi Configuration&lt;/h2&gt;
&lt;p&gt;We need to start by creating our Ouvvi project to hold each Data Sync step in the integration.
To do this open Ouvvi and go to Projects &amp;gt; All Projects &amp;gt; New. Enter in a Name for your project and click &lt;strong&gt;Save&lt;/strong&gt; to continue.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/ouvvi-add-new-project.png" alt="Create New Ouvvi Project" title="Create New Ouvvi Project" /&gt;&lt;/p&gt;
&lt;p&gt;You then need to add a Data Sync step.
For this integration project there are going to be multiple Data Sync steps that will need to be configured to connect to the source data and the relevant Dynamics entity.&lt;/p&gt;
&lt;p&gt;For the purpose of this article we will only focus on the configuring of one step, but the process should be the same for each step in the project.&lt;/p&gt;
&lt;p&gt;To add a Data Sync step go to &lt;strong&gt;Add Step&lt;/strong&gt; &amp;gt; &lt;strong&gt;Data Sync Project&lt;/strong&gt; and then enter in a name for the project and click &lt;strong&gt;Save&lt;/strong&gt;.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/ouvvi-add-datatsync-step-dynamics.png" alt="Add Data Sync Step" title="Add Data Sync Step" /&gt;&lt;/p&gt;
&lt;p&gt;Then open the project by clicking &lt;strong&gt;Open Project&lt;/strong&gt;.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/ouvvi-openproj-dynamicscustomers.png" alt="Open Data Sync" title="Open Data Sync" /&gt;&lt;/p&gt;
&lt;p&gt;When Data Sync has downloaded from Ouvvi and you open the file, you should find that it shows as connected to Ouvvi.
You can check this in four locations:&lt;br /&gt;
1- The title bar&lt;br /&gt;
2- The connection library&lt;br /&gt;
3- The output window&lt;br /&gt;
4- The bottom right of the window&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/ouvvi-connected-datasync.png" alt="Connected to Ouvvi" title="Connected to Ouvvi" /&gt;&lt;/p&gt;
&lt;p&gt;You can now configure the project within Data Sync.&lt;/p&gt;
&lt;h2 id="connect"&gt;Connect to your Source Data&lt;/h2&gt;
&lt;p&gt;In this example we will be configuring the project to import customers from a SQL table into the Dynamics Customers entity.
Please note that you will need to have configured the Accounts import first to ensure this runs without errors. As if you try to lookup the account and it doesn't exist in Dynamics an error will be thrown.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/datasync-customers-preview.png" alt="Customers Sample Data" title="Customers Sample Data" /&gt;&lt;/p&gt;
&lt;p&gt;To do this we need to start by connecting our Source window to our SQL table.
Click onto &lt;strong&gt;Connect Datasource&lt;/strong&gt; to open the connection window, then navigate to &lt;strong&gt;SQL Database&lt;/strong&gt; &amp;gt; &lt;strong&gt;Microsoft SQL Server (SQL Client)&lt;/strong&gt;.&lt;/p&gt;
&lt;p&gt;Enter in the network name of your SQL Server, any credentials you might need to connect and set encryption or trusted certificate as required.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/sqlclient-connection.png" alt="SQl Connection" title="SQL Connection" /&gt;&lt;/p&gt;
&lt;p&gt;Click &lt;strong&gt;Connect &amp;amp; Create Library Connections&lt;/strong&gt; to save this database connection to the connection library. This only needs to be done once per database and will make future project setup easier.&lt;/p&gt;
&lt;p&gt;Select the database and table from the tree view to connect to, and if you are saving to the connection library another window will open where you need to enter a name in for the connection.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/sql-connection-selecttable.png" alt="Select Database" title="Select Database" /&gt;&lt;/p&gt;
&lt;p&gt;This will load the columns in your SQL table into the source window.&lt;/p&gt;
&lt;h2 id="dynamics"&gt;Connect to Dynamics&lt;/h2&gt;
&lt;p&gt;Now we need to connect to Dynamics.
If you haven't configured your connection to Dynamics please see our documentation pages for the &lt;a href="/docs/data-sync/connectors/dynamics/dynamics-oauth-clientcredentials" target="_blank"&gt;full connection guidance details to create your Azure Application&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;Once you have the OAuth connection details from your Azure app click onto the target window and go to Microsoft Dynamics &amp;gt; Microsoft Dynamics 365. Enter int he URL to your Dyanmics site and Data Sync will add the relevant parameters to connect to the SOAP/WCF Service.
Select the custom OAuth Application type from the drop-down and then add your connection details.&lt;/p&gt;
&lt;p&gt;In this example we are using the client credentials flow so we add the ClientID, Client Secret, Token URL V2 endpoint and change the grant type to client_credentials.
Make sure to clear the Redirect URL of any text and then click &lt;strong&gt;Authorise Connection&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;You can then select the entity to connect to, in this case &lt;strong&gt;Contact&lt;/strong&gt; and then save the connection to the connection library by clicking &lt;strong&gt;Connect &amp;amp; Create Library Connection&lt;/strong&gt;.
As we are connected to Ouvvi, this will save the connection to the Ouvvi Connection Library. You only need to save the connection to your Dynamics site once as you will be able to access all of the entities from the one connection.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/images/dynamics-clientcred-selectentity.png" alt="Dynamics Contact Connection" title="Dynamics Contact Connection" /&gt;&lt;/p&gt;
&lt;p&gt;If you already have saved your connection to the connection library, you can either drag and drop the contact entity onto the target or right click and select &lt;strong&gt;Connect to Target (B)&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/dynamics-contacts-connectionlibrary.png" alt="Dynamics Connection Library" title="Dynamics Connection Library" /&gt;&lt;/p&gt;
&lt;h3 id="lookup"&gt;Create the Lookup to Account&lt;/h3&gt;
&lt;p&gt;Now we need to lookup the account IDs in the account entity of Dynamics. To do this we can drag and drop the account entity from the connection library onto the account id column in the source.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/datasync-dynamics-account-lookup-dragdrop.png" alt="Drag and Drop Lookup" title="Drag and Drop Lookup" /&gt;&lt;/p&gt;
&lt;p&gt;Alternatively you can lookup the account by selecting the column to lookup and then clicking onto the lookup button in the source window.
You then select the connection to Dynamics from the connection library tab and select the entity to connect to.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/dynamics-lookup-accountid.png" alt="Lookup Button" title="Lookup Button" /&gt;&lt;/p&gt;
&lt;p&gt;Then to configure the lookup select the target column that will contain the values to be looked up and click OK.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/dynamics-accountlookup-config.png" alt="Lookup Configuration" title="Lookup Configuration" /&gt;&lt;/p&gt;
&lt;p&gt;You can then access all of the columns from the entity you looked up the values for and add these to the schema map as needed.
For this scenario we need the &lt;strong&gt;AccountID&lt;/strong&gt; to link the contact to the right account in Dynamics.&lt;/p&gt;
&lt;h2 id="mapping"&gt;Map the Source &amp;amp; Target Columns&lt;/h2&gt;
&lt;p&gt;The next step is to configure the schema mapping to make sure the columns you need are added and mapped to the corresponding fields in Dynamics.&lt;/p&gt;
&lt;p&gt;You also need to make sure that a key column has been selected that can be used to identify each record as unique. In this case this is the ID column as this will be unique.
You could also use email, or use a composite key such as the lookup1_accountid and the email column if you don't have an external identifier available.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/dynamics-contact-schemamap.png" alt="Schema Mapping" title="Schema Mapping" /&gt;&lt;/p&gt;
&lt;h2 id="compare"&gt;Preview the Results and Sync&lt;/h2&gt;
&lt;p&gt;We now need to preview the results and test synchronise a couple of records to make sure the project is configured correctly.&lt;/p&gt;
&lt;p&gt;To do this click onto the &lt;strong&gt;Compare A &amp;gt; B&lt;/strong&gt; button in the toolbar. This will open the comparison results tab where we can preview the changes that need to be made to make the target (Dynamics) the same as the source (SQL).&lt;/p&gt;
&lt;p&gt;You will be able to preview any adds, updates or deletes that need to be made by clicking onto each option.
Please note that deletes are disabled by default but will still display in the results. If you want to enable deletes then please set EnableDelete to true in the target connection properties.&lt;/p&gt;
&lt;p&gt;For this example we have 546 records to add, 0 to update, and 1 record to delete. As deletes are disabled this record will not be included in the sync.&lt;/p&gt;
&lt;p&gt;If there are no linked accounts for your contacts, then the account does not currently exist in Dynamics.
The corresponding accounts should be added in the account project that will be run before this one. So when the whole integration project is run from Ouvvi, the accounts will be added first and the correct AccountID will be added to these records.
If the account is added at a later date then this will be updated in a future run of the project.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/dynamics-contact-results.png" alt="Results" title="Results" /&gt;&lt;/p&gt;
&lt;p&gt;To test that the sync will work as expected we can deselect the updates and additions and just add a single record from each. To do this click onto the additions (or updates) and select deselect all. Then check the checkbox against a record.&lt;/p&gt;
&lt;p&gt;You can then click &lt;strong&gt;Synchronise&lt;/strong&gt; and &lt;strong&gt;Start&lt;/strong&gt; to sync the record selected.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/dynamics-contact-selectrecords.png" alt="Select records" title="Select Records" /&gt;&lt;/p&gt;
&lt;p&gt;As that went through without an error, we can now save the project and go back to Ouvvi.
Refreshing the page in Ouvvi will show the project details, and you can now configure your remaining projects for the integration.&lt;/p&gt;
&lt;p&gt;Once all the projects are added you can run the whole sequence by clicking onto the &lt;strong&gt;Start Project&lt;/strong&gt; button.&lt;/p&gt;
&lt;p&gt;Next we will configure the trigger to schedule the project automatically.&lt;/p&gt;
&lt;h2 id="schedule"&gt;Schedule&lt;/h2&gt;
&lt;p&gt;Once all the projects have been built and added to Ouvvi you can schedule it to run on a regular basis. For this example I want the project to run at the start of the day.&lt;/p&gt;
&lt;p&gt;To do this we need to add the &lt;strong&gt;Start of Day Trigger&lt;/strong&gt; by going to &lt;strong&gt;Add Trigger&lt;/strong&gt; &amp;gt; &lt;strong&gt;Start of Day&lt;/strong&gt;.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/dynamics-ouvvi-addtrigger-startofday.png" alt="Add Trigger" title="Add Trigger" /&gt;&lt;/p&gt;
&lt;p&gt;The start of day time is configured in the system settings of Ouvvi, and by default this is set to 8am. To change this to a different time please change the time in the system settings.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/ouvvi-startofday-time-settings.png" alt="Start of Day Time - System Settings" title="Start of Day Time - System Settings" /&gt;&lt;/p&gt;
&lt;p&gt;Once the trigger is added to the project it will run everyday at the specified start of day.&lt;/p&gt;
&lt;p&gt;Your final Ouvvi project might look something like this:&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/dynamics-ouvvi-project-overview.png" alt="Ouvvi Project Overview" title="Ouvvi Project Overview" /&gt;&lt;/p&gt;
&lt;h2 id="export"&gt;Exporting Data from Dynamics&lt;/h2&gt;
&lt;p&gt;As well as being able to import data into Dynamics it is likely you also want to export data from your Dynamics entities. Below we will briefly cover the options you have to setup a regular export of your Dynamics data.&lt;/p&gt;
&lt;p&gt;You will want to contain your export projects within Ouvvi so that they can be automated and run at a set schedule, please see the details in the previous section on how to &lt;a href="#ouvvi"&gt;add and configure Ouvvi projects&lt;/a&gt;.
You can see the details on &lt;a href="#trigger"&gt;adding a trigger here&lt;/a&gt; or for more detailed documentation please take a look at our &lt;a href="/docs/ouvvi/training/triggers-add"&gt;training pages&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;Below I am assuming you have already created an Ouvvi project to hold your Data Sync projects and just need to configure an export project.&lt;/p&gt;
&lt;h3 id="connect-dynamics"&gt;Connect to Dynamics&lt;/h3&gt;
&lt;p&gt;If you haven't configured your connection to Dynamics please see our documentation pages for the &lt;a href="/docs/data-sync/connectors/dynamics/dynamics-oauth-clientcredentials" target="_blank"&gt;full connection guidance details to create your Azure Application&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;Once you have the OAuth connection details from your Azure app click onto the target window and go to Microsoft Dynamics &amp;gt; Microsoft Dynamics 365. Enter int he URL to your Dyanmics site and Data Sync will add the relevant parameters to connect to the SOAP/WCF Service.
Select the custom OAuth Application type from the drop-down and then add your connection details.&lt;/p&gt;
&lt;p&gt;In this example we are using the client credentials flow so we add the ClientID, Client Secret, Token URL V2 endpoint and change the grant type to client_credentials.
Make sure to clear the Redirect URL of any text and then click &lt;strong&gt;Authorise Connection&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;You can then select the entity to connect to, in this case &lt;strong&gt;Contact&lt;/strong&gt; and then save the connection to the connection library by clicking &lt;strong&gt;Connect &amp;amp; Create Library Connection&lt;/strong&gt;.
As we are connected to Ouvvi, this will save the connection to the Ouvvi Connection Library. You only need to save the connection to your Dynamics site once as you will be able to access all of the entities from the one connection.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/images/dynamics-clientcred-selectentity.png" alt="Dynamics Contact Connection" title="Dynamics Contact Connection" /&gt;&lt;/p&gt;
&lt;p&gt;If you already have saved your connection to the connection library, you can either drag and drop the contact entity onto the target or right click and select &lt;strong&gt;Connect to Target (B)&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/dynamics-contacts-connectionlibrary.png" alt="Dynamics Connection Library" title="Dynamics Connection Library" /&gt;&lt;/p&gt;
&lt;p&gt;Then add the columns you want to be included in the export to the schema map.&lt;/p&gt;
&lt;h2 id="export-options"&gt;Export Options&lt;/h2&gt;
&lt;p&gt;You have a couple of options to export your data. You can either do a one off export and export to a CSV, Excel, XML or JSON file from the preview tabs; you can use the quick functions from the tools menu e.g. Create CSV File to create a new data source based off the schema properties; or you can connect to an existing data source.&lt;/p&gt;
&lt;h3 id="single"&gt;Single Export to File&lt;/h3&gt;
&lt;p&gt;To do a one off export from the preview just click onto the Preview A button in the schema map to preview the columns added to the schema map.
Alternatively you can export every column from your entity by clicking onto the Preview button in the data source window.&lt;/p&gt;
&lt;p&gt;In the preview window you can then choose between exporting to an XML, CSV, Excel or JSON file. Just click onto the corresponding button and choose where you want the file to be saved.
Your data will then be exported to this file.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/preview-export-options.png" alt="Preview Export Options" title="Preview Export Options" /&gt;&lt;/p&gt;
&lt;h3 id="new"&gt;Export to a New Data Source&lt;/h3&gt;
&lt;p&gt;To create a new data source using the tools menu, just click onto &lt;strong&gt;Tools&lt;/strong&gt; and select the option you want to use. For this example we will create a new CSV file so can use the &lt;strong&gt;Create CSV File&lt;/strong&gt; option.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/tools-menu-createoptions.png" alt="Tools Menu Options" title="Tools Menu Options" /&gt;&lt;/p&gt;
&lt;p&gt;You just need to define a name for the file and select where it should be created and this will be loaded into the data source B window. The columns created will be based upon the columns you added to the schema map previously.&lt;/p&gt;
&lt;p&gt;To synchronise the data to the file just click &lt;strong&gt;Compare A &amp;gt; B&lt;/strong&gt; &amp;gt; &lt;strong&gt;Synchronise&lt;/strong&gt; &amp;gt; &lt;strong&gt;Start&lt;/strong&gt;. You can then save and schedule this project to run in Ouvvi whenever you need it to.&lt;/p&gt;
&lt;h3 id="existing"&gt;Export to an Existing Data Source&lt;/h3&gt;
&lt;p&gt;To export to an existing Data Source you need to connect the target to that source. For example this might be a SharePoint list.&lt;/p&gt;
&lt;p&gt;Click onto the target window to open the connection window and go to &lt;strong&gt;Microsoft SharePoint&lt;/strong&gt; &amp;gt; &lt;strong&gt;Microsoft Office 365 SharePoint Online&lt;/strong&gt; and add the required connection details.
Full connection details can be found in &lt;a href="/docs/data-sync/connectors/sharepoint/sharepoint-oauth"&gt;our documentation pages&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;Map the columns from Dynamics to the corresponding columns in SharePoint and make sure to define a key column that can be used to uniquely identify each record.
You can select a combination of columns to make a composite key if you do not have a column in SharePoint that can take the Dynamics ContactID.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/dynamics-sharepoint-exoprt-schema.png" alt="Export Schema" title="Export Schema" /&gt;&lt;/p&gt;
&lt;p&gt;You can then preview the results by clicking Compare A &amp;gt; B and either run the sync now or save the project and return to Ouvvi to schedule it to run at a later time.&lt;/p&gt;
&lt;h2 id="troubleshoot"&gt;Troubleshooting&lt;/h2&gt;
&lt;p&gt;Below are a couple of errors/issues you might come across and how you can go about resolving them.&lt;/p&gt;
&lt;h3 id="permissions-execution-context"&gt;Permissions - Execution Context&lt;/h3&gt;
&lt;p&gt;If you are finding that your project is failing in Ouvvi but not when you run it locally, then it is likely that your service agent does not have permission to access the resource you are connecting to.&lt;/p&gt;
&lt;p&gt;You can see what the error is by clicking onto the log instance and viewing the log output.
For example, this project connects to a SQL database but the user LAB\REBDEV$ does not have permission to access the database so the project has failed.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/ouvvi-loginfailed-error.png" alt="Login Error" title="Login Error" /&gt;&lt;/p&gt;
&lt;p&gt;To fix this you can either add the service account to the SQL database or you can change the execution context of the project.
To do this click onto the execution context to add specific user details for the project to run under.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/ouvvi-execution-context-location.png" alt="Edit Execution Context" title="Edit Execution Context" /&gt;&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/ouvvi-execution-context-add.png" alt="Add Execution Context" title="Add Execution Context" /&gt;&lt;/p&gt;
&lt;h3 id="greyed-out-start-button"&gt;Greyed Out Start Button&lt;/h3&gt;
&lt;p&gt;Another common issue is that the start button of the project is greyed out and cannot be clicked.
This is usually because the services are not running or the instance does not have an active license key.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/dynamics-ouvvistart-grey.png" alt="Greyed Out Start Button" title="Greyed Out Start Button" /&gt;&lt;/p&gt;
&lt;p&gt;To start the services open the deployment manager, select your Ouvvi instance and click the green play button. Alternatively right click and select &lt;strong&gt;Start Service&lt;/strong&gt;.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/ouvvi-start-service-options.png" alt="Start Service" title="Start Service" /&gt;&lt;/p&gt;
&lt;p&gt;To check if there is a license key activating the instance please go to Settings &amp;gt; Register License Key and you should see a green tick next to the license key and a support and maintenance date on the page.&lt;/p&gt;
&lt;p&gt;If you have any questions or want to know more please email us at support@simego.com or checkout our &lt;a href="/blog/all"&gt;other blog posts&lt;/a&gt;.&lt;/p&gt;
</description>
      <source url="http://www.simego.com/blog">Team Blog</source>
      <pubDate>Tue, 03 May 2022 12:48:01 +0000</pubDate>
    </item>
    <item>
      <link>http://www.simego.com/blog/import-documents-as-attachments-dynamics365</link>
      <author>info@simego.com (Rebecca Allen)</author>
      <title>Importing Documents as Attachments in Dynamics 365</title>
      <description>&lt;p&gt;Data Sync has many uses and if you are already integrating with Dynamics 365 (CRM) then you can quickly import documents as attachments into your Dynamics environment in a few steps.&lt;/p&gt;
&lt;p&gt;The following page will show you an example of how you can import files from your file systems into the attachments entity in Dynamics and link these to a corresponding account.&lt;/p&gt;
&lt;div class="text-center"&gt;&lt;img src="https://images.simego.com/blog/dynamics-files-attachments.png" title="Dynamics File Attachment Integration" alt="Dynamics File Attachment Integration"/&gt;&lt;/div&gt;
&lt;section class="section-tiny alternate-color"&gt;
&lt;div class="container"&gt;
&lt;h3&gt;Contents&lt;/h3&gt;
&lt;ol&gt;
                    &lt;li&gt;
                        &lt;a href="#requirements"&gt;Requirements&lt;/a&gt;
                    &lt;/li&gt;
                    &lt;li&gt;
                        &lt;a href="#source"&gt;Connect to your Source Data&lt;/a&gt;
                    &lt;/li&gt;
                    &lt;li&gt;
                        &lt;a href="#addmetadata"&gt;Create the Metadata Columns&lt;/h3&gt;
                    &lt;/li&gt;
                    &lt;li&gt;
                        &lt;a href="#target"&gt;Connect to Dynamics&lt;/a&gt;
                    &lt;/li&gt;
                    &lt;li&gt;
                        &lt;a href="#lookup"&gt;Lookup Account&lt;/a&gt;
                    &lt;/li&gt;
                    &lt;li&gt;
                        &lt;a href="#mapping"&gt;Configure the Schema Map&lt;/a&gt;
                    &lt;/li&gt;
                    &lt;li&gt;
                        &lt;a href="#compare"&gt;Compare and Sync&lt;/a&gt;
                    &lt;/li&gt;                        
&lt;/ol&gt;
&lt;/div&gt;
&lt;/section&gt;
&lt;h2 id="requirements"&gt;Requirements&lt;/h2&gt;
&lt;p&gt;Before getting started you need to ensure you have the following:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Windows 10 or Windows Server&lt;/li&gt;
&lt;li&gt;Downloaded &amp;amp; Installed Data Synchronisation Studio&lt;/li&gt;
&lt;li&gt;Access to Dynamics 365&lt;/li&gt;
&lt;li&gt;&lt;a href="/docs/data-sync/connectors/dynamics/dynamics-oauth-clientcredentials" target="_blank"&gt;Configured your connection to Dynamics 365 in Data Sync&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;If you do not have &lt;strong&gt;Data Synchronisation Studio&lt;/strong&gt; you can get a &lt;a href="/install/data-synchronisation-studio"&gt;free evaluation edition&lt;/a&gt;.&lt;/p&gt;
&lt;h2 id="source"&gt;Connect to your Source Data&lt;/h2&gt;
The following example is using the file explorer as the source and assumes you have your files arranged into folders. Where the folder name is the name of the account that you want to link the file to.
&lt;p&gt;&lt;img src="https://images.simego.com/blog/dynamics-attachment-folderstructure.png" alt="Folder Structure" title="Folder Structure" /&gt;&lt;/p&gt;
&lt;p&gt;To get started you need to open Data Sync and connect your source to your file system. To do this open the connection window and go to &lt;strong&gt;File System&lt;/strong&gt; &amp;gt; &lt;strong&gt;Files&lt;/strong&gt;, then click onto the ellipsis in the path field to browse for your folders.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/datasync-filesystem-connection.png" alt="Connect File System" title="Connect File System" /&gt;&lt;/p&gt;
&lt;p&gt;Then click &lt;strong&gt;Connect&lt;/strong&gt; to add the connection.&lt;/p&gt;
&lt;h2 id="addmetadata"&gt;Create the Metadata Columns&lt;/h2&gt;
&lt;p&gt;In order to pass the file data to Dynamics this needs to be in the format of a Base64 encoded string.
With Data Sync this can be converted using calculated columns and a simple expression.&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;Don't forget to escape the backslashes in the path otherwise your expression will not work&lt;/p&gt;
&lt;/blockquote&gt;
&lt;div class="lang-csharp editor-colors"&gt;&lt;div style="color:Black;background-color:White;"&gt;&lt;pre&gt;
TOBASE64(System.IO.File.ReadAllBytes(&amp;quot;C:\\Users\\Rebecca\\Documents\\ExampleData\\Documents\\&amp;quot; + FullFileName))
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/calc-columns-base64-conversion.png" alt="Convert Document to Base64" title="Convert Document to Base64" /&gt;&lt;/p&gt;
&lt;p&gt;We also need to include an Object ID Type Code of account, as we will be returning the id of the account objects that are specified in the path to link the documents to each account. This can be done with another calculated column where we just return the string &lt;strong&gt;account&lt;/strong&gt;.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/dynamics-attachment-objecttypecode.png" alt="Return Object ID Type Code" title="Return Object ID Type Code" /&gt;&lt;/p&gt;
&lt;h2 id="target"&gt;Connect your target to Dynamics&lt;/h2&gt;
&lt;p&gt;Next you need to connect your target to the annotation entity of your Dynamics site. As you have already pre-configured your connection and saved this to the connection library you can simply expand your connection and right click on the annotation entity and select &lt;strong&gt;Connect to Target (B)&lt;/strong&gt;.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/dynamics-attachment-connectannotation.png" alt="Connect to Dynamics" title="Connect to Dynamics" /&gt;&lt;/p&gt;
&lt;h2 id="lookup"&gt;Lookup Account&lt;/h2&gt;
&lt;p&gt;You then need to lookup the account name in the account entity of Dynamics using calculated columns.
The expression we use for this is:&lt;/p&gt;
&lt;p&gt;&lt;code&gt;LOOKUPB(&amp;quot;accountid&amp;quot;, &amp;quot;account&amp;quot;, KV(&amp;quot;name&amp;quot;, Path))&lt;/code&gt;&lt;/p&gt;
&lt;p&gt;This will lookup the account id in the account entity when the account name matches the folder name in the path.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/dynamics-attachment-lookupaccount.png" alt="Lookup Account" title="Lookup Account" /&gt;&lt;/p&gt;
&lt;h2 id="mapping"&gt;Configure the Schema Map&lt;/h2&gt;
&lt;p&gt;Now add the columns to the schema map and map them to their corresponding column in Dynamics.
Make sure to set the composite key columns so that the records will return as unique. In this example we use FileName and the lookup column objectid.&lt;/p&gt;
&lt;p&gt;The schema map should then look similar to:&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/dynamics-attachment-schema.png" alt="Mapping" title="Mapping" /&gt;&lt;/p&gt;
&lt;h2 id="compare"&gt;Compare and Sync&lt;/h2&gt;
&lt;p&gt;Now run the compare by clicking onto the &lt;strong&gt;Compare A&amp;gt;B&lt;/strong&gt; button in the toolbar and preview the results.&lt;/p&gt;
&lt;p&gt;As we are adding documents we can see that we have X many documents to add to Dynamics by clicking onto the add item in the results list.
If we were updating an existing attachment document then this would show in the update item.&lt;/p&gt;
&lt;p&gt;Please note that deletes are disabled by default but will still show in the results if the record is not present in the source system.&lt;/p&gt;
&lt;p&gt;To enable deletes please set EnableDeletes to True in the target connection properties.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/dynamics-attachmentimport-results.png" alt="Results" title="Results" /&gt;&lt;/p&gt;
&lt;p&gt;If the data is presenting as expected then you can synchronise the results. To do this click &lt;strong&gt;Synchronise&lt;/strong&gt; and then &lt;strong&gt;Start&lt;/strong&gt; to begin the sync.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/dynamics-attachment-synchronise.png" alt="Synchronise" title="Synchronise" /&gt;&lt;/p&gt;
&lt;p&gt;Your documents will now be added to Dynamics as attachments to each account specified.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/dynamics-attachment-imported.png" alt="Dynamics Results" title="Dynamics Results" /&gt;&lt;/p&gt;
&lt;p&gt;If you want more ideas on how you can integrate with Dynamics take a look at our &lt;a href="/blog"&gt;other blog posts&lt;/a&gt;.
As always if you have any questions please send an email to support@simego.com and we will be happy to help.&lt;/p&gt;
</description>
      <source url="http://www.simego.com/blog">Team Blog</source>
      <pubDate>Fri, 06 May 2022 10:00:00 +0000</pubDate>
    </item>
    <item>
      <link>http://www.simego.com/blog/setting-sharepoint-content-types</link>
      <author>info@simego.com (Rebecca Allen)</author>
      <title>Setting Content Types on SharePoint List Items</title>
      <description>&lt;p&gt;When trying to update SharePoint Document Libraries or SharePoint lists on a regular basis it is useful to be able to set sepcific metadata.&lt;/p&gt;
&lt;p&gt;One type of metadata that you might be interested in setting is Content Types.  Content types allow you to set templates, retention policies and define a group of columns for that type.&lt;/p&gt;
&lt;p&gt;The following page will show you how you can set the Content Types on SharePoint list items and Document Library items using Data Synchronisation Studio.&lt;/p&gt;
&lt;section class="section-tiny alternate-color"&gt;
    &lt;div class="container"&gt;
    &lt;h3&gt;Contents&lt;/h3&gt;
        &lt;ol&gt;
                    &lt;li&gt;
                        &lt;a href="#requirements"&gt;Requirements&lt;/a&gt;
                    &lt;/li&gt;
                    &lt;li&gt;
                        &lt;a href="#start"&gt;Getting Started&lt;/a&gt;
                    &lt;/li&gt;
                    &lt;li&gt;
                        &lt;a href="#calc-columns"&gt;Calculated Columns&lt;/h3&gt;
                    &lt;/li&gt;
                    &lt;li&gt;
                        &lt;a href="#lookup"&gt;Lookup to a Custom List&lt;/a&gt;
                    &lt;/li&gt;
                    &lt;li&gt;
                        &lt;a href="#sync"&gt;Preview &amp;amp; Sync&lt;/a&gt;
                    &lt;/li&gt;                    
        &lt;/ol&gt;
    &lt;/div&gt;
&lt;/section&gt;
&lt;h2 id="requirements"&gt;Requirements&lt;/h2&gt;
&lt;p&gt;Before getting started you need to ensure you have the following:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Windows 10 or Windows Server&lt;/li&gt;
&lt;li&gt;Downloaded &amp;amp; Installed Data Synchronisation Studio&lt;/li&gt;
&lt;li&gt;Access to SharePoint Online&lt;/li&gt;
&lt;li&gt;&lt;a href="/docs/data-sync/connectors/sharepoint/sharepoint-oauth" target="_blank"&gt;Configured your connection to SharePoint Online in Data Sync&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;If you do not have &lt;strong&gt;Data Synchronisation Studio&lt;/strong&gt; you can get a &lt;a href="/install/data-synchronisation-studio"&gt;free evaluation edition&lt;/a&gt;.&lt;/p&gt;
&lt;h2 id="start"&gt;Getting Started &lt;/h2&gt;
To set the content types for an item you need to return the content-type id value from SharePoint. 
&lt;p&gt;If you do not know the ID value that SharePoint is expecting we recommend setting content types for a couple of items manually and then preview the results returned from SharePoint in Data Sync.
You can then make a note of each ID and update your source data accordingly.&lt;/p&gt;
&lt;p&gt;Some common ID types are:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Item: &lt;code&gt;0x0100860DBE824AC9614589A21DCD29DB5448007A823F8834051D4F986EA19A5812FF09&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;Issue: &lt;code&gt;0x01030066DC9B12B8DE924CBD18288FA706EA1C&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;Message: &lt;code&gt;0x010700B796C8AF0D82994A86E8DAF1B01A3FFB&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;Task: &lt;code&gt;0x0108004931F959CF5D224F8A156604BB7B6005&lt;/code&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;You have a couple of options when updating the source data:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Manually update the source data with the correct ID&lt;/li&gt;
&lt;li&gt;Use calculated columns to replace the text value with the ID that matches&lt;/li&gt;
&lt;li&gt;Create a list with the types and IDs and lookup the ID&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;The manual process is self explanatory, but you can find descriptions on how you might configure the other options below.&lt;/p&gt;
&lt;p&gt;You need to start by configuring your Data Sync project so that you are connected to your source data and the target is connected to your SharePoint list you want to update. Then you can choose between creating a calculated column or creating a lookup.&lt;/p&gt;
&lt;h2 id="calc-columns"&gt;Calculated Columns&lt;/h2&gt;
&lt;p&gt;You can use calculated columns and a CASE function to return the relevant ID when the content type name in the source data matches the case in the function.&lt;/p&gt;
&lt;p&gt;The expression below returns the ID for message, item, issue, and task and if the source column contains something that doesn't exist in the expression it will return a default value of the issue ID.&lt;/p&gt;
&lt;div class="lang-csharp editor-colors"&gt;&lt;div style="color:Black;background-color:White;"&gt;&lt;pre&gt;
CASE(ContentTypeName, &lt;span style="color:#A31515;"&gt;&amp;quot;0x0100860DBE824AC9614589A21DCD29DB5448007A823F8834051D4F986EA19A5812FF09&amp;quot;&lt;/span&gt;,
KV(&lt;span style="color:#A31515;"&gt;&amp;quot;Message&amp;quot;&lt;/span&gt;, &lt;span style="color:#A31515;"&gt;&amp;quot;0x010700B796C8AF0D82994A86E8DAF1B01A3FFB&amp;quot;&lt;/span&gt;),
KV(&lt;span style="color:#A31515;"&gt;&amp;quot;Item&amp;quot;&lt;/span&gt;, &lt;span style="color:#A31515;"&gt;&amp;quot;0x0100860DBE824AC9614589A21DCD29DB5448007A823F8834051D4F986EA19A5812FF09&amp;quot;&lt;/span&gt;),
KV(&lt;span style="color:#A31515;"&gt;&amp;quot;Task&amp;quot;&lt;/span&gt;, &lt;span style="color:#A31515;"&gt;&amp;quot;0x0108004931F959CF5D224F8A156604BB7B6005&amp;quot;&lt;/span&gt;),
KV(&lt;span style="color:#A31515;"&gt;&amp;quot;Issue&amp;quot;&lt;/span&gt;, &lt;span style="color:#A31515;"&gt;&amp;quot;0x01030066DC9B12B8DE924CBD18288FA706EA1C&amp;quot;&lt;/span&gt;))
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;p&gt;The syntax for this is:&lt;/p&gt;
&lt;div class="lang-csharp editor-colors"&gt;&lt;div style="color:Black;background-color:White;"&gt;&lt;pre&gt;
CASE(ColumnName, DefaultValue, KV(Value, ValueReturned), KV(Value2, ValueReturned2), KV(Value3, ValueReturned3))
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/sharepoint-contenttype-calccolumn-case.png" alt="Calculated Column" title="Calculated Column" /&gt;&lt;/p&gt;
&lt;p&gt;Clicking &lt;strong&gt;OK&lt;/strong&gt; will create the column in your source window and you can then add this column to the schema map and map this to the &lt;strong&gt;Content Type ID&lt;/strong&gt; column in SharePoint&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/sharepoint-contenttype-calcolumn-schemamapping.png" alt="Schema Mapping - Calc Column" title="Schema Mapping - Calc Column" /&gt;&lt;/p&gt;
&lt;h2 id="lookup"&gt;Lookup to a Custom List&lt;/h2&gt;
&lt;p&gt;If you have a list of content types you want to use within your list or library then you could store these and their corresponding ID's in another list or datasource and perform a lookup on each type.&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;Please be aware that if there is a type that does not exist in the list you create and therefore has no ID being returned SharePoint will default the type to &lt;strong&gt;Item&lt;/strong&gt;.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;Here I have created a SharePoint list to hold the content type names and their corresponding IDs and I will lookup the type name I have listed in my source data against this list to return the relevant ID. This list has been named &lt;strong&gt;ContentTypes&lt;/strong&gt;.&lt;/p&gt;
&lt;p&gt;To create the lookup just drag and drop the ContentType list onto the column in the source data that contains the name of the content type, in this example it is &lt;strong&gt;ContentTypeName&lt;/strong&gt;.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/sharepoint-lookup-contenttype-drag.png" alt="Lookup Content Type" title="Lookup Content Type" /&gt;&lt;/p&gt;
&lt;p&gt;This will then open the lookup configuration window where you can define that it is the content type that is being looked up. This should look similar to the below:&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/sharepoint-contenttype-lookupconfig.png" alt="Lookup Configuration" title="Lookup Configuration" /&gt;&lt;/p&gt;
&lt;p&gt;Click OK to create the lookup and now you can access all of the columns within the ContentTypes list. I'm adding the Content Type ID to the schema map by expanding the lookup columns and checking the checkbox.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/sharepoint-contenttype-lookupcolumn.png" alt="Content Type ID Column" title="Content Type ID Column" /&gt;&lt;/p&gt;
&lt;p&gt;You can then map this column to the &lt;strong&gt;Content Type ID&lt;/strong&gt; in your SharePoint list, and add any additional columns you need. Please make sure to select a key column that can be used to identify each record, in this case it is Title.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/sharepoint-contenttype-schemamapping.png" alt="Schema Mapping" title="Schema Mapping" /&gt;&lt;/p&gt;
&lt;p&gt;To show you that the lookup is working I have added in the column from the source that returns the content type name and previewed the data to show the different IDs that are returned.&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;Make sure you remove the Content Type Name column before synchronising as this will throw an &amp;quot;Invalid Request Error&amp;quot; if you try to synchonise to it.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/sharepoint-contenttype-datasample.png" alt="Data Sample" title="Data Sample" /&gt;&lt;/p&gt;
&lt;h2 id="sync"&gt;Preview &amp;amp; Sync&lt;/h2&gt;
&lt;p&gt;We can then preview the changes to be made to add these to SharePoint by clicking &lt;strong&gt;Compare A &amp;gt; B&lt;/strong&gt;.&lt;/p&gt;
&lt;p&gt;This will show us any add, update or delete actions that need to be performed to make the SharePoint list match the source data.&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;Please note that deletes are disabled by default but will still show in the results if the record does not exist in the source data set.&lt;/p&gt;
&lt;p&gt;To enable deletes please set &lt;strong&gt;EnableDelete&lt;/strong&gt; to &lt;strong&gt;True&lt;/strong&gt; in the target connection properties.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;There are 6 records to add and we can now synchronise the results by clicking &lt;strong&gt;Synchronise&lt;/strong&gt; and then &lt;strong&gt;Start&lt;/strong&gt;.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/sharepoint-contenttype-sync.png" alt="Synchronise" title="Synchronise" /&gt;&lt;/p&gt;
&lt;p&gt;The records will then be added and updated in SharePoint with the corresponding content type.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/sharepoint-contenttype-results.png" alt="Results in SharePoint" title="Results in SharePoint" /&gt;&lt;/p&gt;
&lt;p&gt;You can now save the project to be used again in the future or you can schedule it to run on a regular basis using either &lt;a href="/docs/ouvvi/training/tour"&gt;Ouvvi&lt;/a&gt; or the &lt;a href="/docs/data-sync/run-tool/intro"&gt;Run Tool&lt;/a&gt;.&lt;/p&gt;
</description>
      <source url="http://www.simego.com/blog">Team Blog</source>
      <pubDate>Tue, 10 May 2022 10:00:00 +0000</pubDate>
    </item>
    <item>
      <link>http://www.simego.com/blog/creating-dynamics-365-activities</link>
      <author>info@simego.com (Rebecca Allen)</author>
      <title>Creating Dynamics 365 Activity Records</title>
      <description>&lt;p&gt;To create activities such as phonecalls, appointements, tasks and emails in Dynamics you need to provide the GUID of the item you are adding and sync this to the corresponding entity.
For example tasks will need to be synced to the &lt;strong&gt;Task&lt;/strong&gt; entity, phone calls to the &lt;strong&gt;Phonecall&lt;/strong&gt; entity, appointments to the &lt;strong&gt;Appointment&lt;/strong&gt; entity and so on.&lt;/p&gt;
&lt;p&gt;Below we will cover a few of the considerations for each activity type and how you might map the columns&lt;/p&gt;
&lt;section class="section-tiny alternate-color"&gt;
&lt;div class="container"&gt;
&lt;h3&gt;Contents&lt;/h3&gt;
&lt;ol&gt;
                    &lt;li&gt;
                        &lt;a href="#requirements"&gt;Requirements&lt;/a&gt;
                    &lt;/li&gt;
                    &lt;li&gt;
                        &lt;a href="#considerations"&gt;Considerations&lt;/a&gt;
                    &lt;/li&gt;    
                    &lt;li&gt;
                        &lt;a href="#phonecall"&gt;Adding Phonecall Activities&lt;/a&gt;
                    &lt;/li&gt;
                    &lt;li&gt;
                        &lt;a href="#appointments"&gt;Adding Appointment Activities&lt;/a&gt;
                    &lt;/li&gt;
                    &lt;li&gt;
                        &lt;a href="#emails"&gt;Adding Email Activities&lt;/a&gt;
                    &lt;/li&gt;
                    
&lt;/ol&gt;
&lt;/div&gt;
&lt;/section&gt;
&lt;h2 id="requirements"&gt;Requirements&lt;/h2&gt;
&lt;p&gt;Before getting started you need to ensure you have the following:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Windows 10 or Windows Server&lt;/li&gt;
&lt;li&gt;Downloaded &amp;amp; Installed Data Synchronisation Studio&lt;/li&gt;
&lt;li&gt;Access to Dynamics 365&lt;/li&gt;
&lt;li&gt;&lt;a href="/docs/data-sync/connectors/dynamics/dynamics-oauth-clientcredentials" target="_blank"&gt;Configured your connection to Dynamics 365 in Data Sync&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;If you do not have &lt;strong&gt;Data Synchronisation Studio&lt;/strong&gt; you can get a &lt;a href="/install/data-synchronisation-studio"&gt;free evaluation edition&lt;/a&gt;.&lt;/p&gt;
&lt;h2 id="connect"&gt;Considerations&lt;/h2&gt;
&lt;p&gt;If you are regularly updating activity records in Dynamics then we would recommend containing all of your projects within an Ouvvi project.
This will enable you to run each project on a schedule and run them in sequence.
You can additionally add a step to notify you that the project has completed and the details of what changed.&lt;/p&gt;
&lt;p&gt;You can find more details on the &lt;a href="/docs/ouvvi/steps/ouvvi-project-status"&gt;project status report step&lt;/a&gt; in our documentation. Alternatively you could also use the &lt;a href="/docs/data-sync/run-tool/intro"&gt;Run Tool&lt;/a&gt; to schedule your projects.&lt;/p&gt;
&lt;p&gt;If your source data is a selection of different activity types then you can filter the source records to only return the activity type you are trying to update.
For example you could filter the source with the expression &lt;code&gt;activitytype == &amp;quot;phonecall&amp;quot;&lt;/code&gt; to filter the results to return only phonecalls.&lt;/p&gt;
&lt;p&gt;The below examples assume you have already connected to Dynamics and saved the connection to the connection library, and that you have your source connected to your source data.&lt;/p&gt;
&lt;h2 id="phonecall"&gt;Adding Phonecall Activities&lt;/h2&gt;
&lt;p&gt;To write phone call activities you must connect the target to the &lt;strong&gt;Phonecall&lt;/strong&gt; entity and provide the data in the format &lt;strong&gt;Entity Name| GUID of the Item&lt;/strong&gt;.
We recommend adding a record manually so then you can preview the format that Dynamics is expecting.&lt;/p&gt;
&lt;p&gt;For phone call activities you need to supply the following fields at a minimum:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;from&lt;/strong&gt; - The user that made the call in the format &lt;code&gt;systemuser|systemuserid&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;to&lt;/strong&gt; - The account or contact that the call relates to in the format &lt;code&gt;account|accountid&lt;/code&gt; or &lt;code&gt;contact|contactid&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;subject&lt;/strong&gt; - The subject of the call&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;activityid&lt;/strong&gt; - A guid to uniquely identify each activity&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;You can then additionally add in other metadata such as a description, duration, date, ownerid, ownertype etc.as you need.&lt;/p&gt;
&lt;p&gt;A sample of the data we are returning for this can be seen below:&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/dynamics-phonecall-sampledata.png" alt="Data Preview" title="Data Preview" /&gt;&lt;/p&gt;
&lt;p&gt;You will need to lookup the account name in your Dynamics site to return the account id so that we can present the &lt;strong&gt;to&lt;/strong&gt; field in the format expected in a few moments.&lt;/p&gt;
&lt;p&gt;If your data is linking to a contact record rather than account then you can follow the same details as below but lookup the contactid in the Contact entity and return the id in the format &lt;strong&gt;contact|contactidGUID&lt;/strong&gt; e.g. &lt;code&gt;contact|14daefde-d3d1-ec11-a7b5-00224880a494&lt;/code&gt;.&lt;/p&gt;
&lt;p&gt;Drag and drop the account entity onto the source column that contains the account name, e.g. &lt;strong&gt;Account&lt;/strong&gt;.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/dynamics-activities-lookup-account-phonecall.png" alt="Drag and Drop Lookup Account" title="Drag and Drop Lookup Account" /&gt;&lt;/p&gt;
&lt;p&gt;This will open the lookup configuration window where you will need to specify the column within the account entity to lookup the source values. In this case &lt;strong&gt;name&lt;/strong&gt;. Click OK to save this and create the lookup.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/dynamics-activities-lookupconfig-account-phonecall.png" alt="Account Lookup Config" title="Account Lookup Config" /&gt;&lt;/p&gt;
&lt;p&gt;Now repeat this for the system user entity to lookup the user by fullname.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/dynamics-activities-lookupconfig-systemuser.png" alt="System User Lookup Config" title="System User Lookup Config" /&gt;&lt;/p&gt;
&lt;p&gt;We can now use calculated columns to return the entity name and GUID in the format we mentioned earlier.&lt;/p&gt;
&lt;p&gt;To do this click onto the fx button in the datasource toolbar, enter in name for the column and make sure the data type is set appropriately.&lt;/p&gt;
&lt;p&gt;&lt;code&gt;CONCAT(&amp;quot;account|&amp;quot;, STR(Lookup1_accountid))&lt;/code&gt;&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/dynamics-activities-phonecall-tocolumn-format.png" alt="Calculated Column format to field" title="Calculated Column format to field" /&gt;&lt;/p&gt;
&lt;p&gt;Alternatively you can do the lookup in the function rather than creating it separately:&lt;/p&gt;
&lt;p&gt;&lt;code&gt;CONCAT(&amp;quot;account|&amp;quot;, STR(LOOKUPB(&amp;quot;accountid&amp;quot;, &amp;quot;account&amp;quot;,WHEN(&amp;quot;name&amp;quot;, Account))))&lt;/code&gt;&lt;/p&gt;
&lt;p&gt;You need to do this for both the to and from fields.&lt;/p&gt;
&lt;p&gt;Once they have been created we can then map these columns to the schema map and link them to their corresponding field in Dynamics.
You can now add any additional columns you might need and make sure to set a unique key column that can be used to identify each phone call activity.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/dynamics-phonecall-activities-schema.png" alt="Schema Mapping" title="Schema Mapping" /&gt;&lt;/p&gt;
&lt;p&gt;To run the sync click &lt;strong&gt;Compare A &amp;gt; B&lt;/strong&gt; to view the changes that need to be made, and check the preview to ensure the data looks as you expect.
Here we have 5 phonecalls to add, note that deletes show in the results but are disabled by default. To enable them please set EnableDeletes to True in the target connection properties.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/dynamics-phonecall-activities-results.png" alt="Compare Results" title="Compare Results" /&gt;&lt;/p&gt;
&lt;p&gt;Once you are ready click &lt;strong&gt;Synchronise&lt;/strong&gt; and &lt;strong&gt;Start&lt;/strong&gt; to begin the sync.&lt;/p&gt;
&lt;p&gt;You can now save you project and move on to creating the projects to sync other activities.&lt;/p&gt;
&lt;h2 id="appointments"&gt;Adding Appointment Activities&lt;/h2&gt;
&lt;p&gt;Adding appointments as activities to your Dynamics site is very similar to adding phonecalls, the main difference being you connect to the appointment entity as your target and there are different required fields.&lt;/p&gt;
&lt;p&gt;At a minimum the columns you need are:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;activityid&lt;/strong&gt; - A guid to uniquely identify the activity.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;organiser&lt;/strong&gt; - The user the appointment is with in the format &lt;code&gt;systemuser|systemuserid&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;requiredattendiees&lt;/strong&gt; - The contact or account that the appointment is with in the format &lt;code&gt;contact|contactid&lt;/code&gt; or &lt;code&gt;account|accountid&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;scheduledstart&lt;/strong&gt;&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;scheduledend&lt;/strong&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;If you want to change the status of the appointment you can do so by adding &lt;strong&gt;statecode&lt;/strong&gt;: 1 is completed, 2 is cancelled and 3 is scheduled.&lt;/p&gt;
&lt;p&gt;A preview of the data we are using for this example can be seen below:&lt;/p&gt;
&lt;p&gt;We need to lookup the contactid and the systemuserid and then format the values.&lt;/p&gt;
&lt;p&gt;First start with the lookups. Drag and drop the &lt;strong&gt;contact&lt;/strong&gt; entity onto the contact column in the source, and then configure the lookup to target the contact full name as this is the data we have in the source file.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/dynamics-appt-lookupconfig-contact-fullname.png" alt="Lookup Format - Contact" title="Lookup Format - Contact" /&gt;&lt;/p&gt;
&lt;p&gt;We can then repeat this for system user. Drag and drop the &lt;strong&gt;systemuser&lt;/strong&gt; entity onto the organiser column and then configure the lookup to target the full name of the user.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/dynamics-activities-lookupconfig-organiser-fullname.png" alt="Lookup Format - System User" title="Lookup Format - System User" /&gt;&lt;/p&gt;
&lt;p&gt;Now we can create the calculated columns to format the values.
Lets start with the organiser. Create a calculated column and use the following expression to concatenate &lt;strong&gt;systemuser|&lt;/strong&gt; with the systemuserid.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/dynamics-activities-appt-organiser-format.png" alt="Calculated Column - Organiser Format" title="Calculated Column - Organiser Format" /&gt;&lt;/p&gt;
&lt;p&gt;For the contact, create a calculated column and use the following expression to concatenate &lt;strong&gt;contact|&lt;/strong&gt; with the contactid.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/dynamics-activities-appt-contact-format.png" alt="Calculated Column - Contact Format" title="Calculated Column - Contact Format" /&gt;&lt;/p&gt;
&lt;p&gt;You can now add these new column to the schema map alongside the other required fields and any other fields you want to include.
Your schema mapping should now look similar to this:&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/dynamics-activities-appointment-schema.png" alt="Appointments Schema Mapping" title="Appointments Schema Mapping" /&gt;&lt;/p&gt;
&lt;p&gt;To finish simply compare, preview &amp;amp; check the results, and then synchronise the changes to import your appointment activities.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/dynamics-appointment-activities-results.png" alt="Appointment Compare Results" title="Appointment Compare Results" /&gt;&lt;/p&gt;
&lt;h2 id="emails"&gt;Adding Email Activities&lt;/h2&gt;
&lt;p&gt;To synchronise emails as activities in Dynamics you need to connect your target to the email entity and include a few more required columns.
The example below uses a document to contain the message details rather than connecting the source to exchange.&lt;/p&gt;
&lt;p&gt;The columns you need to include are:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;activityid&lt;/strong&gt; - A guid to identify each activity as unique&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;from&lt;/strong&gt; - The system user who sent the email in the format &lt;code&gt;systemuser|systemuserid&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;to&lt;/strong&gt; - The contact that the email is being sent to in the format &lt;code&gt;contact|contactid&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;subject&lt;/strong&gt; - The email subject&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;description&lt;/strong&gt; - The body of the email in either HTML or plain text&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;regardingobjecttype&lt;/strong&gt; - The type of object the email relates to in this case a &amp;quot;contact&amp;quot;&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;regardingobjectid&lt;/strong&gt; - The ID of the contact it relates to&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;By default the email will be set to draft status, however if you want to define this then you can do so by setting the &lt;strong&gt;statuscode&lt;/strong&gt;: 1 is draft and 3 is sent.&lt;/p&gt;
&lt;p&gt;Below is a preview of the data we are using in this example.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/dynamics-email-sampledata.png" alt="Data Preview" title="Data Preview" /&gt;&lt;/p&gt;
&lt;p&gt;We need to start by looking up the contact id and the sender id and then format this into the format &lt;code&gt;object|objectid&lt;/code&gt;.&lt;/p&gt;
&lt;p&gt;To add the lookup to contact drag the contact entity from the connection library onto the contact column in the source.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/dynamics-activities-lookup-contact-email.png" alt="Drag Drop Lookup Contact" title="Drag Drop Lookup Contact" /&gt;&lt;/p&gt;
&lt;p&gt;Then configure the lookup so that the value is being looked up in the correct column. In this example as we have the full name we join the lookup on &lt;strong&gt;fullname&lt;/strong&gt;.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/dynamics-activities-lookupconfig-contact-fullname.png" alt="Contact Lookup Config" title="Contact Lookup Config" /&gt;&lt;/p&gt;
&lt;p&gt;To add the lookup to the system user drag the &lt;strong&gt;systemuser&lt;/strong&gt; entity from the connection library onto the sender column in the source.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/dynamics-activities-lookup-user-email.png" alt="Drag Drop Lookup System User" title="Drag Drop Lookup System User" /&gt;&lt;/p&gt;
&lt;p&gt;Then configure the lookup so that the value is being looked up in the correct column. In this example as we have the email of the sender we join the lookup on &lt;strong&gt;domainname&lt;/strong&gt;.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/dynamics-activities-lookupconfig-systemuser-domain.png" alt="System User Lookup Config" title="System User Lookup Config" /&gt;&lt;/p&gt;
&lt;p&gt;We now need to use the lookups to format the to and from columns. This can be done using calculated columns and the functions described below.&lt;/p&gt;
&lt;p&gt;To format the &lt;strong&gt;to&lt;/strong&gt; column we can use calculated columns with the expression:&lt;/p&gt;
&lt;p&gt;&lt;code&gt;CONCAT(&amp;quot;contact|&amp;quot;,STR(Lookup1_contactid))&lt;/code&gt;&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/dynamics-activities-email-tocolumn-format.png" alt="Calculated Column - To Formatting" title="Calculated Column - To Formatting" /&gt;&lt;/p&gt;
&lt;p&gt;To format the &lt;strong&gt;from&lt;/strong&gt; column we can use calculated columns with the expression:&lt;/p&gt;
&lt;p&gt;&lt;code&gt;CONCAT(&amp;quot;systemuser|&amp;quot;, STR(Lookup2_systemuserid))&lt;/code&gt;&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/dynamics-activities-email-fromcolumn-format.png" alt="Calculated Column - From Formatting" title="Calculated Column - From Formatting" /&gt;&lt;/p&gt;
&lt;p&gt;These can now be added to the schema map and linked to their corresponding column in Dynamics.
Your schema map should look something similar to below with a key column selected.&lt;/p&gt;
&lt;p&gt;You can get the contactid to map to the &lt;strong&gt;regardingobjectid&lt;/strong&gt; column from the lookup. Just expand the lookup columns and select the &lt;strong&gt;Lookup1_contactid&lt;/strong&gt; column.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/dynamics-activities-email-schema.png" alt="Schema Mapping - Emails" title="Schema Mapping - Emails" /&gt;&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;If you need to add multiple recipients you can do so by supplying them separated by semi colon e.g. &lt;code&gt;contact|77962dc3-fcd5-ec11-a7b5-000d3abdf148;contact|969924e0-7c2c-4e85-be9d-000d3abdf148&lt;/code&gt;&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;You can now compare and sync as normal to import your email activities.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/dynamics-email-activities-results.png" alt="Email Sync Results" title="Email Sync Results" /&gt;&lt;/p&gt;
&lt;p&gt;Don't forget to save your project so that you can use it again at a later date. If you upload it into Ouvvi or the Run Tool it can be scheduled to run on a regular basis.&lt;/p&gt;
&lt;p&gt;If you have any questions please send us an email at support@simego.com.&lt;/p&gt;
</description>
      <source url="http://www.simego.com/blog">Team Blog</source>
      <pubDate>Tue, 17 May 2022 12:55:33 +0000</pubDate>
    </item>
    <item>
      <link>http://www.simego.com/blog/dynamics-365-synchronisation-optimisations</link>
      <author>info@simego.com (Rebecca Allen)</author>
      <title>Performance and Optimisation Strategies for Dynamics Synchronisations</title>
      <description>&lt;p&gt;Data Sync is fantastic at getting data in and out of Dynamics, however it is limited by the Dynamics API.
When uploading large volumes of data you need to optimise your settings so then you don't hit the Dynamics threshold limits and then get throttled, which will slow your synchronisation to a snails pace.&lt;/p&gt;
&lt;p&gt;The following page covers some considerations and tips on how to make the most out of Data Sync and optimise your Dynamics 365 integrations.&lt;/p&gt;
&lt;div class="text-center"&gt;&lt;img src="https://images.simego.com/blog/dynamics-optimisations.png" title="Dynamics Synchronisation Optimisations" alt="Dynamics Synchronisation Optimisations"/&gt;&lt;/div&gt;
&lt;section class="section-tiny alternate-color"&gt;
&lt;div class="container"&gt;
&lt;h3&gt;Contents&lt;/h3&gt;
&lt;ol&gt;
                    &lt;li&gt;
                        &lt;a href="#extract"&gt;API Limits&lt;/a&gt;
                    &lt;/li&gt;
                    &lt;li&gt;
                        &lt;a href="#sql-table"&gt;Threads &amp; Batch Size&lt;/a&gt;
                    &lt;/li&gt;
                    &lt;li&gt;
                        &lt;a href="#real-time"&gt;Real-Time Data&lt;/a&gt;
                    &lt;/li&gt;                   
&lt;/ol&gt;
&lt;/div&gt;
&lt;/section&gt;
&lt;h2 id="threshold"&gt;API Limits&lt;/h2&gt;
&lt;p&gt;The Dynamics / PowerPlatform implements request limits to maintain a reliable service for customers. This is a complex area and is based on the license type and other factors this may also change at any moment due to Microsoft changing the service.
You can read more on their current limit allocations within the &lt;a href="https://docs.microsoft.com/en-us/power-platform/admin/api-request-limits-allocations" target="_blank"&gt;Microsoft Documentation pages here&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;Typically you will see the following errors in the log if your hitting the limits:&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;RateLimitExceeded&lt;/strong&gt;&lt;br /&gt;
&lt;strong&gt;TimeLimitExceeded&lt;/strong&gt;&lt;br /&gt;
&lt;strong&gt;ConcurrencyLimitExceeded&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;Each of these error are a temporary error that occurs when the Dynamics API is throttled. We have built into Data Sync a feature so that it will automatically back off and try the request again up to 5 times.&lt;/p&gt;
&lt;p&gt;In general its better to avoid hitting the API limits and use lower batch and thread settings. If you keep hitting the limits then this will be slower overall due to continually having to back off the requests.&lt;/p&gt;
&lt;h2 id="threads"&gt;Threads &amp; Batch Size&lt;/h2&gt;
&lt;p&gt;Within the Dynamics connector you can define the number of threads and batch size to use when synchronising the changes.&lt;/p&gt;
&lt;p&gt;If you increase the Batch size to be greater than &lt;strong&gt;1&lt;/strong&gt; then the requests are sent as &lt;strong&gt;ExecuteMultipleRequests&lt;/strong&gt; messages. You can send a maximum of 1000 requests in a single message.
We recommend using a batch size of &lt;strong&gt;10 or less&lt;/strong&gt; if your using a high thread count otherwise 50 should work well. Using the maximum is generally really slow and will not help your synchronisation performance.&lt;/p&gt;
&lt;p&gt;If you increase the Thread count to be greater than &lt;strong&gt;1&lt;/strong&gt; then requests will be sent in parallel. If the batch size is larger than 10, alongside an increased thread count, you may see &lt;strong&gt;ConcurrencyLimitExceeded&lt;/strong&gt; errors. This is because by default you can only run &lt;strong&gt;two ExecuteMultipleRequests&lt;/strong&gt; calls at a time unless you contact Microsoft Support and get this limit increased.&lt;/p&gt;
&lt;p&gt;A baseline configuration to start with is a thread count of 4 and a batch size of 10.
If your not seeing any errors after say 20K records then you can try increasing the thread count.&lt;/p&gt;
&lt;h2 id="real-time"&gt;Real-Time Data&lt;/h2&gt;
&lt;p&gt;Getting real-time integrations is hard, however you can get very close by using Ouvvi in combination with Data Sync in incremental mode with an appropriate filter and a Trigger to detect the changes.
Using this method will typically apply changes to the target within 1 minute.&lt;/p&gt;
&lt;p&gt;You would start by creating a project in Ouvvi to hold your Data Sync project(s), then add a Data Sync step and configure the project to do your Synchronisation.&lt;/p&gt;
&lt;p&gt;You can then set incremental mode by going to &lt;strong&gt;File&lt;/strong&gt; &amp;gt; &lt;strong&gt;Properties&lt;/strong&gt; &amp;gt; &lt;strong&gt;SyncOption&lt;/strong&gt; and setting the value to &lt;strong&gt;SyncAtoBIncremental&lt;/strong&gt;.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/datasync-setincremantal-properties.png" alt="Set Incremental - Properties" title="Set Incremental - Properties" /&gt;&lt;/p&gt;
&lt;p&gt;Alternatively you can set incremental mode from the main toolbar.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/datasync-setincremantal-toolbar.png" alt="Set Incremental - Toolbar" title="Set Incremental - Toolbar" /&gt;&lt;/p&gt;
&lt;p&gt;You would then configure your Data Sync project as normal applying any filters to reduce the datasets being returned, and save your project back to Ouvvi. By reducing the dataset being returned you will speed up the synchronisation thus allowing you to get closer to real-time updates.
You could use the &lt;strong&gt;modifiedon&lt;/strong&gt; column from Dynamics to filter for records that were modified today, perhaps within the last hour.&lt;/p&gt;
&lt;p&gt;Once your project has been created and saved back to Ouvvi you can configure either a time trigger, to run your project at a regular interval, or you can use an event trigger to run your project when a change is detected e.g. in a Dynamics entity.
Event triggers are called every 30 seconds by Ouvvi to check if there have been any changes, this is how you can get close to real-time synchronisations. Every time a change is detected in an entity (the modified timestamp changes) the project will be automatically run.&lt;/p&gt;
</description>
      <source url="http://www.simego.com/blog">Team Blog</source>
      <pubDate>Thu, 26 May 2022 12:55:33 +0000</pubDate>
    </item>
    <item>
      <link>http://www.simego.com/blog/dynamics-make-record-inactive</link>
      <author>info@simego.com (Rebecca Allen)</author>
      <title>Making Dynamics 365 Items Inactive rather than Deleting them</title>
      <description>&lt;p&gt;When integrating with Dynamics you might need to mark items that are no longer needed as inactive rather than deleting them completely. Logically making something inactive is easy but the physical difference when synchronising items is more involved.&lt;/p&gt;
&lt;p&gt;The following blog will discuss how you can set entity items to inactive rather than deleting them.
We will be synchronising a Supplier table from a SQL database into the Account Entity in Dynamics 365.&lt;/p&gt;
&lt;div class="text-center"&gt;&lt;img src="https://images.simego.com/blog/dynamics-entity-inactive.png" title="Dynamics Entity Inactive" alt="Dynamics Entity Inactive"/&gt;&lt;/div&gt;
&lt;section class="section-tiny alternate-color"&gt;
&lt;div class="container"&gt;
&lt;h3&gt;Contents&lt;/h3&gt;
&lt;ol&gt;
                    &lt;li&gt;
                        &lt;a href="#requirements"&gt;Requirements&lt;/a&gt;
                    &lt;/li&gt;
                    &lt;li&gt;
                        &lt;a href="#considerations"&gt;Considerations&lt;/a&gt;
                    &lt;/li&gt;    
                    &lt;li&gt;
                        &lt;a href="#project1"&gt;Project 1 - Adding New and Updating Existing Records&lt;/a&gt;
                    &lt;/li&gt;
                    &lt;ul&gt;
                        &lt;li&gt;
                            &lt;a href="#fetchxml"&gt;Filter Target for Active and Supplier Records using FetchXML&lt;/a&gt;
                        &lt;/li&gt;
                        &lt;li&gt;
                            &lt;a href="#typecode"&gt;Set the CustomerTypeCode&lt;/a&gt;
                        &lt;/li&gt;
                        &lt;li&gt;
                            &lt;a href="#mapping"&gt;Configure the Schema Map&lt;/a&gt;
                        &lt;/li&gt;
                        &lt;li&gt;
                            &lt;a href="#compare"&gt;Compare and Synchronise&lt;/a&gt;
                        &lt;/li&gt;
                    &lt;/ul&gt;
                    &lt;li&gt;
                        &lt;a href="#project2"&gt;Project 2 - Setting the Inactive Status&lt;/a&gt;
                    &lt;/li&gt;
                    &lt;ul&gt;
                        &lt;li&gt;
                            &lt;a href="#lookup"&gt;Create the Lookup&lt;/a&gt;
                        &lt;/li&gt;
                        &lt;li&gt;
                            &lt;a href="#filter"&gt;Filter to only show items to be deleted&lt;/a&gt;
                        &lt;/li&gt;
                        &lt;li&gt;
                            &lt;a href="#statecode"&gt;Set StateCode to Inactive&lt;/a&gt;
                        &lt;/li&gt;
                        &lt;li&gt;
                            &lt;a href="#statuscode"&gt;Set StatusCode to Inactive&lt;/a&gt;
                        &lt;/li&gt;
                        &lt;li&gt;
                            &lt;a href="#schema"&gt;Configure the Schema Map&lt;/a&gt;
                        &lt;/li&gt;
                        &lt;li&gt;
                            &lt;a href="#sync"&gt;Compare and Synchronise&lt;/a&gt;
                        &lt;/li&gt;
                    &lt;/ul&gt;                   
&lt;/ol&gt;
&lt;/div&gt;
&lt;/section&gt;
&lt;h2 id="requirements"&gt;Requirements&lt;/h2&gt;
&lt;p&gt;Before getting started you need to ensure you have the following:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Windows 10 or Windows Server&lt;/li&gt;
&lt;li&gt;Downloaded &amp;amp; Installed Data Synchronisation Studio&lt;/li&gt;
&lt;li&gt;Access to Dynamics 365&lt;/li&gt;
&lt;li&gt;&lt;a href="/docs/data-sync/connectors/dynamics/dynamics-oauth-clientcredentials" target="_blank"&gt;Configured your connection to Dynamics 365 in Data Sync&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;If you do not have &lt;strong&gt;Data Synchronisation Studio&lt;/strong&gt; you can get a &lt;a href="/install/data-synchronisation-studio"&gt;free evaluation edition&lt;/a&gt;.&lt;/p&gt;
&lt;h2 id="considerations"&gt;Considerations&lt;/h2&gt;
&lt;p&gt;If you are regularly updating activity records in Dynamics then we would recommend containing all of your projects within an Ouvvi project.
This will enable you to run each project on a schedule and run them in sequence.
You can additionally add a step to notify you that the project has completed and the details of what changed.&lt;/p&gt;
&lt;p&gt;You can find more details on the &lt;a href="/docs/ouvvi/steps/ouvvi-project-status"&gt;project status report step&lt;/a&gt; in our documentation. Alternatively you could also use the &lt;a href="/docs/data-sync/run-tool/intro"&gt;Run Tool&lt;/a&gt; to schedule your projects.&lt;/p&gt;
&lt;p&gt;These are the parameters we need to consider and set to make an entity item inactive or active:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;When a Supplier exists in the SQL Table but is not active or Inactive in the Account entity, create it and set it to Active.&lt;/li&gt;
&lt;li&gt;When a Supplier exists in the SQL Table but Inactive in the Account entity, set to Active and update any fields.&lt;/li&gt;
&lt;li&gt;When a Supplier exists in the SQL Table and exists as Active in the Account entity, update required fields.&lt;/li&gt;
&lt;li&gt;When a Supplier does not exists in the SQL Table and exists as Active set to Inactive&lt;/li&gt;
&lt;li&gt;When a Supplier does not exists in the SQL Table and exists as Inactive, do nothing.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;To do this we will create two Data Sync projects, which will allow us to create, update and mark items as inactive rather than deleting them.&lt;/p&gt;
&lt;p&gt;The first project is a simple synchronisation between the SQL Supplier table and &lt;strong&gt;Active&lt;/strong&gt; Accounts of type &lt;strong&gt;Supplier&lt;/strong&gt; (&lt;strong&gt;customertypecode&lt;/strong&gt; of 10) with deletes disabled (&lt;strong&gt;EnableDeletes=False&lt;/strong&gt;).
This adds any new entities and updates any details that might have changed.&lt;/p&gt;
&lt;p&gt;The second project maps the &lt;strong&gt;Account&lt;/strong&gt; entity to itself but uses a lookup to see if the underlying record still exists in the SQL Supplier table. If the lookup returns no data then it is missing and the status should be changed to &lt;strong&gt;InActive&lt;/strong&gt;.&lt;/p&gt;
&lt;h2 id="project1"&gt;Project 1 - Adding New and Updating Existing Records&lt;/h2&gt;
&lt;p&gt;We need to start by creating the project that will add and update records within the Account entity.&lt;/p&gt;
&lt;p&gt;To do this open Data Sync and connect the source to the Supplier table (SQL) and the target to the Account entity in Dynamics.
Make sure to leave &lt;strong&gt;EnableDelete&lt;/strong&gt; set to &lt;strong&gt;false&lt;/strong&gt;, which is the default value.&lt;/p&gt;
&lt;h3 href="fetchxml"&gt;Filter Target for Active and Supplier Records Only&lt;/h3&gt;
&lt;p&gt;We now need to use a FetchXML filter on the target data source (Dynamics) to remove any inactive records and to only return the supplier customer type (code 10).&lt;/p&gt;
&lt;p&gt;You can add a FetchXML filter to the target by entering the filter into the FetchXMLFilter property field found in the target connection properties (below the columns).
Click onto the ellipsis to open the editor and enter your FetchXML statement.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/images/dynamics-add-fetchxml-filter.png" alt="Filter Field" title="Filter Field" /&gt;&lt;/p&gt;
&lt;p&gt;An example of the FetchXML filter you could use is:&lt;/p&gt;
&lt;div class="lang-xml editor-colors"&gt;&lt;div style="color:Black;background-color:White;"&gt;&lt;pre&gt;
&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;filter&lt;/span&gt; &lt;span style="color:Red;"&gt;type&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;and&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;condition&lt;/span&gt; &lt;span style="color:Red;"&gt;attribute&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;statecode&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;operator&lt;/span&gt; &lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;eq&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;value&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;0&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;condition&lt;/span&gt; &lt;span style="color:Red;"&gt;attribute&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;customertypecode&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;operator&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;eq&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;value&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;10&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
&lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;filter&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;p&gt;This filter will be applied when we run the compare later on. You can check it is correct by previewing the target data using the preview button in the datasource toolbar.&lt;/p&gt;
&lt;h3 href="typecode"&gt;Set the CustomerTypeCode&lt;/h3&gt;
&lt;p&gt;The next step is to set the &lt;strong&gt;customertypecode&lt;/strong&gt; to 10 to set the records as &lt;strong&gt;Suppliers&lt;/strong&gt; within the account entity.
To do this we can create a calculated column in the source by clicking onto the &lt;strong&gt;fx&lt;/strong&gt; button.
Then enter in a name for the column e.g.&lt;strong&gt;customertypecode&lt;/strong&gt;, set the data type to &lt;strong&gt;System.Int32&lt;/strong&gt; and enter in &lt;strong&gt;10&lt;/strong&gt; for the expression.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/dynamics-inactive-setcustomertypecode.png" alt="Set Customer Type Code" title="Set Customer Type Code" /&gt;&lt;/p&gt;
&lt;p&gt;Clicking &lt;strong&gt;OK&lt;/strong&gt; will create the column which can then be added to the schema map.&lt;/p&gt;
&lt;h3 href="mapping"&gt;Configure the Schema Map&lt;/h3&gt;
&lt;p&gt;We now need to configure the schema map so that the calculated column we just created is linked to the corresponding column in Dynamics (&lt;strong&gt;customertypecode&lt;/strong&gt;).
Then continue to add and map the columns from the source table to the Accounts entity in Dynamics as you need, and make sure to add a column that is unique to each record e.g. in this example is the &lt;strong&gt;SupplierID&lt;/strong&gt; which is linked to the &lt;strong&gt;accountnumber&lt;/strong&gt; field.&lt;/p&gt;
&lt;p&gt;Your mapping should now look similar to this:&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/dynamics-inactive-schemamap.png" alt="Schema Mapping Project 1" title="Schema Mapping Project 1" /&gt;&lt;/p&gt;
&lt;h3 href="compare"&gt;Compare and Synchronise the Results&lt;/h3&gt;
&lt;p&gt;The next step is to run the comparision to preview the differences between the source SQL table and the target Account entity.&lt;/p&gt;
&lt;p&gt;Do this by clicking onto the &lt;strong&gt;Compare A &amp;gt; B&lt;/strong&gt; button in the toolbar.
In the screen capture below we can see that there are 29 records to add.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/dynamics-inactive-addsuppliers-results.png" alt="Compare Results - Add Suppliers" title="Compare Results - Add Suppliers" /&gt;&lt;/p&gt;
&lt;p&gt;Now click &lt;strong&gt;Synchronize&lt;/strong&gt; and &lt;strong&gt;Start&lt;/strong&gt; to apply the updates to Account Entity.&lt;/p&gt;
&lt;p&gt;Make sure to save the project so that you can use it again.&lt;/p&gt;
&lt;h2 id="project2"&gt;Project 2 - Setting the Inactive Status&lt;/h2&gt;
&lt;p&gt;We will now create the second project which will set the status to inactive on records that do not exist in the SQL supplier table.&lt;/p&gt;
&lt;p&gt;Start by setting the Account entity from Dynamics as the &lt;strong&gt;source&lt;/strong&gt; and &lt;strong&gt;target&lt;/strong&gt; in your Data Sync project, and keep &lt;strong&gt;EnableDelete&lt;/strong&gt; set to &lt;strong&gt;False&lt;/strong&gt;. This will prevent any accidental deletion of your data.&lt;/p&gt;
&lt;p&gt;We need to add the FetchXML statement we used in the first project, so that only the supplier records are targeted in the Account Entity.
If we didn't filter the records then it would set all account records not included in the supplier table to inactive.&lt;/p&gt;
&lt;div class="lang-xml editor-colors"&gt;&lt;div style="color:Black;background-color:White;"&gt;&lt;pre&gt;
&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;filter&lt;/span&gt; &lt;span style="color:Red;"&gt;type&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;and&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;condition&lt;/span&gt; &lt;span style="color:Red;"&gt;attribute&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;statecode&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;operator&lt;/span&gt; &lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;eq&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;value&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;0&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;condition&lt;/span&gt; &lt;span style="color:Red;"&gt;attribute&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;customertypecode&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;operator&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;eq&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;value&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;10&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
&lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;filter&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;p&gt;Make sure to add this to the source and target datasets.&lt;/p&gt;
&lt;h3 id="lookup"&gt;Create the Lookup&lt;/h3&gt;
&lt;p&gt;The next step is to create a lookup on the account name in the source by dragging the supplier table from the connection library onto the &lt;strong&gt;name&lt;/strong&gt; column in the source.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/dynamics-inactive-lookupsupplierdrag.png" alt="Lookup Supplier Name" title="Lookup Supplier Name" /&gt;&lt;/p&gt;
&lt;p&gt;You then need to define the lookup configuration setting the target lookup column to be the &lt;strong&gt;CompanyName&lt;/strong&gt; from the SQL table.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/dynamics-inactive-lookupsupplier-config.png" alt="Lookup Configuration" title="Lookup Configuration" /&gt;&lt;/p&gt;
&lt;p&gt;Here we have essentially joined the Account entity in Dynamics to the SQL Table.&lt;br /&gt;
If there is no corresponding record in the SQL table then we know it has been deleted and we need to set entity to inactive.&lt;/p&gt;
&lt;h3 id="filter"&gt;Filter to only show deleted items&lt;/h3&gt;
&lt;p&gt;We need to then add a filter to the source data to only return rows that have nothing returned from the lookup.&lt;/p&gt;
&lt;p&gt;&lt;code&gt; ISNULL(Lookup1_SupplierID)&lt;/code&gt;&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/dynamics-inactive-filtersupplieridnull.png" alt="Filter for Null Supplier" title="Filter for Null Supplier" /&gt;&lt;/p&gt;
&lt;h3 id="statecode"&gt;Set State Code to InActive&lt;/h3&gt;
&lt;p&gt;We are now going to use calculated columns to set the &lt;strong&gt;statecode&lt;/strong&gt; and &lt;strong&gt;statuscode&lt;/strong&gt; to the correct values depending on whether the lookup can find the existing items in the SQL Suppliers table.&lt;/p&gt;
&lt;p&gt;The state code field is expecting a string value and the value for inactive is &lt;strong&gt;1&lt;/strong&gt;, so we can do this by adding a new calculated column that returns &lt;strong&gt;1&lt;/strong&gt;.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/dynamics-inactive-setstatecode.png" alt="State Code Calculated Column" title="State Code Calculated Column" /&gt;&lt;/p&gt;
&lt;h3 id="statuscode"&gt;Set Status Code to InActive&lt;/h3&gt;
&lt;p&gt;Then repeat the same steps to create a calculated column to return the &lt;strong&gt;statuscode&lt;/strong&gt;. The status code field is a Int32 field and the value for inactive is &lt;strong&gt;2&lt;/strong&gt;.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/dynamics-inactive-setstatuscode.png" alt="Status Code Calculated Column" title="Status Code Calculated Column" /&gt;&lt;/p&gt;
&lt;h3 id="statuscode"&gt;Configure the Schema Map&lt;/h3&gt;
&lt;p&gt;We now need to configure the schema map and add the calculated columns we just created making sure to join them with their corresponding target columns &lt;strong&gt;statecode&lt;/strong&gt; and &lt;strong&gt;statuscode&lt;/strong&gt;.&lt;/p&gt;
&lt;p&gt;Make sure to define a key column that can be used to uniquely identify each record, in this case &lt;strong&gt;accountid&lt;/strong&gt;.
You should only need these three columns and your schema map should now look similar to this:&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/dynamics-inactive-schemaupdate.png" alt="Schema Map" title="Schema Map" /&gt;&lt;/p&gt;
&lt;h3 href="sync"&gt;Compare and Synchronise the Results&lt;/h3&gt;
&lt;p&gt;To finish we need to compare the source to the target by clicking the &lt;strong&gt;Compare A &amp;gt; B&lt;/strong&gt; button in the toolbar.
We can then preview the data to check the results by clicking onto the different result lines.&lt;/p&gt;
&lt;p&gt;In this example we can see that there is one row missing in the SQL Supplier table (showing as an update) so that record needs to be updated to inactive status.
The 29 records showing as delete items are the suppliers that exist in the SQL table but have been filtered out for the synchronisation. As deletes are disabled they will not be affected by this synchronisation.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/dynamics-inactive-compareresults.png" alt="Compare" title="Compare Results" /&gt;&lt;/p&gt;
&lt;p&gt;To make this record inactive click &lt;code&gt;Synchronize&lt;/code&gt; and &lt;code&gt;Start&lt;/code&gt; to apply the changes.&lt;/p&gt;
&lt;p&gt;You can now save this project and schedule both projects to run in sequence using either &lt;a href="/docs/ouvvi/training/tour"&gt;Ouvvi&lt;/a&gt; or the &lt;a href="/docs/data-sync/run-tool/intro"&gt;Run Tool&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;For more examples on integrating with Dynamics take a look at our &lt;a href="/blog/all"&gt;other blog posts&lt;/a&gt;. Alternatively if you have any questions please send us an email at support@simego.com.&lt;/p&gt;
</description>
      <source url="http://www.simego.com/blog">Team Blog</source>
      <pubDate>Mon, 27 Jun 2022 12:55:33 +0000</pubDate>
    </item>
    <item>
      <link>http://www.simego.com/blog/ouvvi-datasync-upcoming-changes</link>
      <author>info@simego.com (Rebecca Allen)</author>
      <title>Upcoming Changes to Data Sync and Ouvvi</title>
      <description>&lt;p&gt;In 2023 we will be releasing a new version of Data Synchronisation Studio and Ouvvi Automation Server, these will both be labelled as Version 6.0.
Data Sync has jumped from V3 to V6 to keep the version numbers in-line with Ouvvi, as it there have been many releases over the years and it was time to start afresh.&lt;/p&gt;
&lt;p&gt;There are a number of changes that have been made to improve the user experience of Ouvvi and the integration of Data Sync and Ouvvi, as well as updating the backend to use .NET Standard.
The following page will cover the changes that have been made so far and how you use each feature, as you can &lt;a href="/install/data-synchronisation-studio-beta" target="_blank"&gt;download a functioning preview version now&lt;/a&gt;.&lt;/p&gt;
&lt;div class="text-center"&gt;&lt;img src="https://images.simego.com/blog/datasync-version6-splashscreen.png" title="Data Sync V6 Splash screen" alt="Data Sync V6 Splash screen"/&gt;&lt;/div&gt;
 
&lt;section class="section-tiny alternate-color"&gt;
&lt;div class="container"&gt;
&lt;h3&gt;Contents&lt;/h3&gt;
&lt;ol&gt;
                    &lt;li&gt;
                        &lt;a href="#considerations"&gt;Considerations&lt;/a&gt;
                    &lt;/li&gt; 
                    &lt;li&gt;
                        &lt;a href="#datasync"&gt;Data Sync Changes&lt;/a&gt;
                    &lt;/li&gt;
                    &lt;ul&gt;
                        &lt;li&gt;
                            &lt;a href="#connection-library"&gt;Copy your Connection Library&lt;/a&gt;
                        &lt;/li&gt;
                    &lt;/ul&gt;
                    &lt;li&gt;
                        &lt;a href="#datasync-open-ouvvi"&gt;Opening Ouvvi Steps in Data Sync&lt;/a&gt;
                    &lt;/li&gt;
                    &lt;ul&gt;
                        &lt;li&gt;
                            &lt;a href="#new-project"&gt;Create an Ouvvi Project&lt;/a&gt;
                        &lt;/li&gt;
                        &lt;li&gt;
                            &lt;a href="#new-ds-step"&gt;Create a New Data Sync Step&lt;/a&gt;
                        &lt;/li&gt;
                    &lt;/ul&gt;
                    &lt;li&gt;
                        &lt;a href="#ouvviui"&gt;Ouvvi UI changes&lt;/a&gt;
                    &lt;/li&gt;
                    &lt;ul&gt;
                        &lt;li&gt;
                            &lt;a href="#overlay-windows"&gt;Overlay Windows&lt;/a&gt;
                        &lt;/li&gt;
                        &lt;li&gt;
                            &lt;a href="#button-functionality"&gt;Button Functionality&lt;/a&gt;
                        &lt;/li&gt;
                    &lt;/ul&gt;                    
                    &lt;li&gt;
                        &lt;a href="#ouvvi-setup"&gt;Configuring Ouvvi&lt;/a&gt;
                    &lt;/li&gt;
                    &lt;ul&gt;
                        &lt;li&gt;
                            &lt;a href="#authentication-types"&gt;Authentication Options&lt;/h3&gt;
                        &lt;/li&gt;
                        &lt;li&gt;
                            &lt;a href="#service-setup"&gt;Service Configuration&lt;/h3&gt;
                        &lt;/li&gt;
                        &lt;li&gt;
                            &lt;a href="#ouvvi-connections"&gt;OAuth Connections&lt;/h3&gt;
                        &lt;/li&gt;
                        &lt;li&gt;
                            &lt;a href="#ipfilter"&gt;IP Filtering&lt;/h3&gt;
                        &lt;/li&gt;
                    &lt;/ul&gt;
                    &lt;li&gt;
                        &lt;a href="#misc"&gt;Miscellaneous&lt;/a&gt;
                    &lt;/li&gt;
                    &lt;ul&gt;
                    &lt;li&gt;
                            &lt;a href="#back-end"&gt;Back End Changes&lt;/a&gt;
                        &lt;/li&gt;
                        
                    &lt;/ul&gt;
                                      
&lt;/ol&gt;
&lt;/div&gt;
&lt;/section&gt;
&lt;h2 id="considerations"&gt;Considerations&lt;/h2&gt;
&lt;p&gt;Before getting started we recommend you take a backup of your Ouvvi Database and any local Data Sync projects.
Once you have updated your Ouvvi database you will be unable to downgrade back to version 4 without using a backup to restore your site settings.&lt;/p&gt;
&lt;p&gt;You can install and run Data Sync V6 alongside V3, so that you can choose between the versions depending on the project you are working with.&lt;/p&gt;
&lt;p&gt;Any local Data Sync projects will open using Version 6 and once changes have been made and saved you may not be able to open all of your projects in Data Sync V3 (if you decide to downgrade).
You will still be able to access Data Sync V3 from the start menu, but the default version will be V6.&lt;/p&gt;
&lt;p&gt;Your license key can be used to activate both Data Sync V3 and V6 so long as they are both installed on the same machine, as they will both have the same Client ID.&lt;/p&gt;
&lt;p&gt;Your local connection library will need copying to the new V6 location to be used in your projects, but this will be covered in a &lt;a href="#connection-library"&gt;section below&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;The following page assumes you have taken all the backups you need and you have downloaded and installed the latest version from the &lt;a href="/install/data-synchronisation-studio-beta"&gt;preview page&lt;/a&gt;.&lt;/p&gt;
&lt;h2 id="datasync"&gt;Data Sync Changes&lt;/h2&gt;
&lt;p&gt;From the moment of downloading you will notice there are a couple of visual differences to Data Sync, the first being the new colours for the splash screen and Icon, and the second being the new icon.
We decided to change the colour and icon to make it easier to tell the difference between the versions from a quick glance.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/datasync-icon.png" alt="Data Sync V6 Icon" title="Data Sync V6 Icon" /&gt;&lt;/p&gt;
&lt;p&gt;Alongside this minor visual change there have been a number of changes in the architecture of Data Sync.&lt;/p&gt;
&lt;p&gt;The Data Sync core libraries have been updated to run on .NET Standard in preparation for the move to .NET Core in the future and the code base reduced and tidied to contain only what is needed.
We've also updated the UI and Data Connectors framework to run .NET v4.8 which was released back in 2019 so should be compatible with most systems.&lt;/p&gt;
&lt;p&gt;The code complier has been upgraded to be based on Roslyn. This is now running on C# Version 7.3, whereas previously the code compiler was running C# Version 4.0
This means you can now use the latest C# syntax in Calculated Columns, Dynamic Columns and Project Automation. For example you can use the null-coalescing operator&lt;code&gt;??&lt;/code&gt; and functions such as &lt;code&gt;$&amp;quot;Hello{ID}&amp;quot;&lt;/code&gt; to replace values in a string with data from a specified column.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/datasync-v6-codesyntax.png" alt="New C# Function Compatibility" title="New C# Function Compatibility" /&gt;&lt;/p&gt;
&lt;p&gt;Currently the code editor is a few versions behind the compiler and so does not recognise the new C# syntax, but we are hoping to update this in the new year.
For the time being you will get the squiggly line under any of this syntax but the code will still build.&lt;/p&gt;
&lt;p&gt;At the moment the custom connectors on github and any connector that uses the &lt;strong&gt;Install custom connector function&lt;/strong&gt; will not work as they need reworking to reference the correct code base. This will be handled before the final release but is currently not a functioning feature.
If you have built your own custom connector for using in Data Sync you will need to rebuild it to get the latest code base.&lt;/p&gt;
&lt;p&gt;An additional feature we have added is to make it possible to open your Ouvvi Data Sync steps within the Data Sync designer. This is covered in more detail in the &lt;a href="#datasync-open-ouvvi"&gt;section below&lt;/a&gt;.&lt;/p&gt;
&lt;h3 id="connection-library"&gt;Copy the Local Connection Library&lt;/h3&gt;
&lt;p&gt;When you first open Data Sync V6 you will find your connection library isn't automatically imported. You will need to copy your current connections over or re-create them in the designer.&lt;/p&gt;
&lt;p&gt;To copy your current local connections open the registry folder for Data Sync V3, by default this is usually &lt;code&gt;C:\ProgramData\Simego\DataSyncStudio30\Registry&lt;/code&gt; .
Then copy the connection files and paste them into the registry folder for Data Sync V6, by default this is &lt;code&gt;C:\ProgramData\Simego\DataSyncStudio60\Registry&lt;/code&gt;.&lt;/p&gt;
&lt;p&gt;Your connections will then be available to use from the connection library window in Data Sync.&lt;/p&gt;
&lt;p&gt;For Ouvvi, if you have upgraded your version using the deployment manager, your connections should still be in the database. However there may be some connection types that no longer function and will need updating.&lt;/p&gt;
&lt;h2 id="datasync-open-ouvvi"&gt;Opening Ouvvi Steps in Data Sync&lt;/h2&gt;
&lt;p&gt;You will be able to connect and open your Data Sync projects stored within your Ouvvi site from Data Sync.
We're hoping that this will make it easier and more obvious on how to edit your projects when they are stored within your Ouvvi Database.
To access the projects from Data Sync go to the &lt;strong&gt;File&lt;/strong&gt; menu and select &lt;strong&gt;Open Ouvvi Project&lt;/strong&gt;.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/ds-open-ouvvi-project.png" alt="Open Ouvvi Project" title="Open Ouvvi Project" /&gt;&lt;/p&gt;
&lt;p&gt;This will open the Ouvvi Connection Window where you need to enter in the URL to your Ouvvi site (by default this is usually &lt;code&gt;http://localhost:8080&lt;/code&gt;) and click &lt;strong&gt;Connect&lt;/strong&gt;.
You will then be able to see your groups, projects and steps.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/ds-ouvvi-connection-overview.png" alt="Connect to Ouvvi-Data Sync" title="Connect to Ouvvi-Data Sync" /&gt;&lt;/p&gt;
&lt;p&gt;From this connection window you will be able to open your Data Sync steps, create new projects within your Ouvvi site and provision/create Data Sync steps within your projects. We will cover how to do this in a moment.&lt;/p&gt;
&lt;p&gt;To open your Data Sync step simply double click and it will be opened in the Data Sync window.
This will download a local copy to your download folder but whilst it shows as connected to Ouvvi (see toolbar, connection library, output window and status bar), you will be using the Ouvvi connection library and saving any changes back to your Ouvvi site.&lt;/p&gt;
&lt;p&gt;You can connect to different Ouvvi sites by entering each URL, and can switch between them by selecting the URLs from the dropdown.&lt;/p&gt;
&lt;h3 id="new-project"&gt;Create an Ouvvi Project&lt;/h3&gt;
&lt;p&gt;Within the Connection Window to Ouvvi in Data Sync you can design your Projects by creating new Projects and Data Sync Steps. This can either be to quickly mock up your project or to fully build and devleop it.&lt;/p&gt;
&lt;p&gt;To create a new project in Ouvvi right click onto the site URL in the tree view to add a project outside of a group, or right click onto the group you want to add the project to and select &lt;strong&gt;Add Project&lt;/strong&gt;.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/ds-ouvvi-connection-create-project.png" alt="Create New Ouvvi Project" title="Create New Ouvvi Project" /&gt;&lt;/p&gt;
&lt;p&gt;This will open a window where you can define the project name, then click OK to create it.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/ds-ouvvi-newproject.png" alt="Create New Project" title="Create New Project" /&gt;&lt;/p&gt;
&lt;p&gt;This will then add the project to the tree and you can add Data Sync Steps as needed.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/ds-ouvvi-newproject-created.png" alt="New Project Created" title="New Project Created" /&gt;&lt;/p&gt;
&lt;h3 id="new-ds-step"&gt;Create a New Data Sync Step&lt;/h3&gt;
&lt;p&gt;To create a new Data Sync Step, right click onto the project you want to add it to and select &lt;strong&gt;Add DataSync Step&lt;/strong&gt;.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/ds-ouvvi-connection-create-step.png" alt="Create New DS Step" title="Create New DS Step" /&gt;&lt;/p&gt;
&lt;p&gt;This will open a new window where you can enter in the name for hte step, the retry count and the run condition.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/ds-ouvvi-newdsstep.png" alt="Create New Step" title="Create New Step" /&gt;&lt;/p&gt;
&lt;p&gt;The step will then be added to the tree and you can double click it to open it in Data Sync. The project will be connected to Ouvvi and any changes you make and save will be uploaded into Ouvvi automatically.
You can tell when the project is connected to Ouvvi in 4 locations:&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;&lt;strong&gt;The Title Bar&lt;/strong&gt; : This will show the URL to your Ouvvi project&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;The Connection Library&lt;/strong&gt; : This will show &lt;strong&gt;[Ouvvi]&lt;/strong&gt; in the title bar of the window&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;The Output Window&lt;/strong&gt; : This will show the URL to your Ouvvi project in the output for the connection library&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;The Footer Bar&lt;/strong&gt; : To the right of the footer you will find the URL to the Ouvvi registry (connection library)&lt;/li&gt;
&lt;/ol&gt;
&lt;p&gt;If none of the above are showing then you are not connected to Ouvvi and you will need to follow the steps again to re-open the project.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/ds-connected-ouvvi-v6.png" alt="Connected to Ouvvi" title="Connected to Ouvvi" /&gt;&lt;/p&gt;
&lt;h2 id="ouvviui"&gt;Ouvvi UI Changes&lt;/h2&gt;
&lt;p&gt;When you now browse to your Ouvvi site you will notice that the UI has been changed. This follows a similar style to Ouvvi V2.5 however uses a few different styles and has better navigational options.
We also have dark themes available under system settings.&lt;/p&gt;
&lt;p&gt;Our key reasoning behind the UI change was to improve your experience when using Ouvvi. We found it seemed difficult to find functions on the page, and explanations of how to do something became cumbersome.
We also noticed that you can quickly loose your position when performing tasks and if you wanted to carry on editing a project you would need to re-navigate back to it.&lt;/p&gt;
&lt;p&gt;You will now notice all of the navigation appears at the top of the page, there is a main toolbar and a small navigation menu that will appear when necessary.
Within the small toolbar you will find the functions relating to the page you are currently on. Taking the project overview page shown below, you can find the navigation back to the view all projects page along with the add step and trigger functions within the small sub-toolbar..&lt;/p&gt;
&lt;p&gt;For the steps within the project you can now choose to open or edit them from the dropdown, this reduces the number of pages you need to navigate and then number of clicks to perform the actions. If the step is a Data Sync step you will also have the option to open the project in Data Sync to allow you to edit the proejct as you need.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/ouvvi-v6-project-overview.png" alt="Ouvvi Overview Page" title="Ouvvi Overview Page" /&gt;&lt;/p&gt;
&lt;p&gt;On some pages you will find quick function buttons, and some functions will now be performed in overlay windows instead of on a new page.&lt;/p&gt;
&lt;p&gt;In the sections below we will cover a few of these and where you might find them.&lt;/p&gt;
&lt;h3 href="overlay-windows"&gt;Overlay Windows&lt;/h3&gt;
&lt;p&gt;To further help with navigation, we felt that there were too many page changes when you wanted to do something simple such as edit a user setting, copy a step and deleting a step etc.&lt;/p&gt;
&lt;p&gt;To achieve this we have now made simple actions an overlay popup window so that you can quickly perform these tasks and do not loose where you were in Ouvvi.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/ouvvi-overlay-copystep.png" alt="PopUp Windows Ouvvi" title="PopUp Windows Ouvvi" /&gt;&lt;/p&gt;
&lt;p&gt;You will find these interspersed throughout the UI and can either perform the task, click the cross or click away from the overlay to close the window.&lt;/p&gt;
&lt;h3 href="button-functionality"&gt;Button Functionality&lt;/h3&gt;
&lt;p&gt;Another feature that has been added is a series of quick function buttons. These range from ending a process, reseting the queue, adding a service agent and so on.&lt;/p&gt;
&lt;p&gt;The idea behind this is to remove the need for you to access the database directly and be able to perform everything you need to from the browser.
This will allow users to resolve these issues, as the database is not always accessible for all users.&lt;/p&gt;
&lt;p&gt;For example, in the past if the Server got unexpectedly restarted and the queue got stuck, you would need to access the Ouvvi database to drop the items in the queue table to get your projects back up and running.
Now you simply navigate to the queue table and click &lt;strong&gt;Reset Queue&lt;/strong&gt;.&lt;/p&gt;
&lt;p&gt;Note that you need to have stopped your services before clicking reset to prevent other issues.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/ouvvi-reset-queue-button.png" alt="Reset Queue Button" title="Reset Queue Button" /&gt;&lt;/p&gt;
&lt;p&gt;Another button like this is the &lt;strong&gt;Reset Trigger Clock&lt;/strong&gt; which can be found on the Triggers page.&lt;/p&gt;
&lt;p&gt;If you can think of any other quick functions you would find useful in your Ouvvi site, get in touch with us and we can see if we can add them to the build.&lt;/p&gt;
&lt;h2 id="ouvvi-setup"&gt;Configuring Ouvvi&lt;/h2&gt;
&lt;p&gt;Understanding authentication options and service user accounts can be confusing, but in this update we have tried to make the Ouvvi setup and configuration as straight forward as we currently can, trying to lead users through the steps with a next, next, next pattern.&lt;/p&gt;
&lt;p&gt;The deployment manager has also been changed so that it disables editing the configuration unless it has been uninstalled, as none of the changes will be applied until it is uninstalled and reinstalled.
This is all to make it clearer to users when items can and cannot be changed.&lt;/p&gt;
&lt;h3 id="authentication-types"&gt;Ouvvi Authentication Options&lt;/h3&gt;
&lt;p&gt;In Ouvvi V6 we have made it possible to choose your preferred authentication type.
You can choose between Windows and Forms authentication during the initial configuration and then you can further choose to use Azure AD credentials.&lt;/p&gt;
&lt;p&gt;Windows Authentication uses local machine users, whereas Forms Authentication allows you to define your own usernames and passwords or use Azure AD Credentials.&lt;/p&gt;
&lt;p&gt;You can specify the authentication type in the deployment manager configuration window by changing the drop down option.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/ouvvi-authentication-options.png" alt="Authentication Type Deployment Manager" title="Authentication Type Deployment Manager" /&gt;&lt;/p&gt;
&lt;p&gt;If you selected &lt;strong&gt;Windows&lt;/strong&gt; Authentication it will continue to use Windows Accounts via Integrated Security managed by IIS as before.&lt;/p&gt;
&lt;p&gt;If you selected &lt;strong&gt;Forms&lt;/strong&gt; Authentication then you can choose between using Windows Accounts (Local Domain Accounts) or Internal Ouvvi Accounts to sign into Ouvvi on the setup page. If you select Internal accounts you can later configure Ouvvi to use Azure AD Credentials to sign in.&lt;/p&gt;
&lt;h4&gt;Azure AD Accounts&lt;/h4&gt;
&lt;p&gt;To make Ouvvi use your Azure AD credentials for users you need to first browse to Ouvvi and make sure the Authentication Mode drop-down is set to &lt;strong&gt;Internal Accounts&lt;/strong&gt;.
Then enter in a set of credentials you want to act as the default account. This will be used to sign in to Ouvvi until you have configured the Azure AD connection.&lt;/p&gt;
&lt;p&gt;Now go to Settings &amp;gt; System Settings and click onto the &lt;strong&gt;Azure AD&lt;/strong&gt; button in the sub toolbar menu.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/ouvvi-azuread-configbutton.png" alt="Azure AD Button" title="Azure AD Button" /&gt;&lt;/p&gt;
&lt;p&gt;You then need to setup an Azure AD app to enable the connection, making sure to use the redirect URL listed on the Ouvvi Azure AD Setup page.
From the app you need to enter the Tenant (Directory) ID and Client (Application) ID, then click &lt;strong&gt;Continue&lt;/strong&gt;.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/ouvvi-azuread-configuration.png" alt="Azure AD Authentication" title="Azure AD Authentication" /&gt;&lt;/p&gt;
&lt;p&gt;The setup will then guide you to sign in to your Microsoft account and accept the permissions.&lt;/p&gt;
&lt;p&gt;You will then need to enter the Client Secret for your Azure App, and click &lt;strong&gt;Save&lt;/strong&gt; to finish the setup.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/ouvvi-azuread-config-clientsecret.png" alt="Azure AD Client Secret" title="Azure AD Client Secret" /&gt;&lt;/p&gt;
&lt;p&gt;You will then be signed out and will need to sign in again with the account you used to accept the permissions.
This will be the default account with admin permissions. You can then specify additional users under the user profiles section by adding their logon name and setting the permission level.&lt;/p&gt;
&lt;h4&gt;Internal Accounts&lt;/h4&gt;
&lt;p&gt;Another option is to specify your own user accounts/credentials. To do this change the drop down to &lt;strong&gt;Internal Accounts&lt;/strong&gt; and set the user credentials to act as the default system admin.
You can then add additional user accounts to Ouvvi under Settings &amp;gt; User Profiles.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/ouvvi-formsauth-internalaccounts.png" alt="Internal Accounts Auth" title="Internal Accounts Auth" /&gt;&lt;/p&gt;
&lt;h4&gt;Windows Accounts &lt;/h4&gt;
&lt;p&gt;To do this, browse to Ouvvi and make sure the Authentication Mode drop down is set to &lt;strong&gt;Windows Accounts&lt;/strong&gt;.
Then enter in the local domain user account you want to use as the default admin.&lt;/p&gt;
&lt;h3 id="service-setup"&gt;Service Configuration&lt;/h3&gt;
&lt;p&gt;One of the biggest problems we have is users not completing the Ouvvi setup and wondering why the services don't start. So the main focus was trying to make the service setup and configuration a more guided experience.
Ouvvi will now redirect you to the setup page if you have not completed the setup and guide you through adding a Service User to the Ouvvi Profiles.&lt;/p&gt;
&lt;h4&gt;Forms Authentication&lt;/h4&gt;
&lt;p&gt;If you click &lt;strong&gt;Start Service&lt;/strong&gt; before finishing the configuration then you will be redirected to the setup page where you will need to configure the default system admin account and finish setting up the database.
Once you have completed the setup you can go back to the deployment manager and try to start the service again. If it is successful you will be redirected to the services page and green flags will show to show that they are running.&lt;/p&gt;
&lt;p&gt;If you do not have a service user specified then it will redirect to the services page and you can create a new service user by using the button in the browser.&lt;/p&gt;
&lt;p&gt;When using Forms Authentication you can also change the Service User Credentials from the deployment manager. To do this right click onto your instance and select &lt;strong&gt;Set Service Ouvvi Credentials&lt;/strong&gt;.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/ouvvi-set-service-credentials.png" alt="Set Ouvvi Service Credentials" title="Set Ouvvi Service Credentials" /&gt;&lt;/p&gt;
&lt;p&gt;You then specify the Username and Password for the user and click OK.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/ouvvi-set-service-credentials-window.png" alt="Set Service Credentials Window" title="Set Service Credentials Window" /&gt;&lt;/p&gt;
&lt;p&gt;If you have configured your Instance to use Azure AD credentials then clicking &lt;strong&gt;Start Service&lt;/strong&gt; with redirect you straight to the &lt;strong&gt;Configure Ouvvi Agent Services&lt;/strong&gt; page where you can change the username of the agent or leave the default name. This will create a service agent for the machine you are currently on.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/ouvvi-azuread-autoagentconfig.png" alt="Agent Config" title="Agent Config" /&gt;&lt;/p&gt;
&lt;h4&gt;Windows Authentication&lt;/h4&gt;
&lt;p&gt;If you are using Windows authentication, when you have installed Ouvvi and right click to proceed with the setup, if you click onto the &lt;strong&gt;Start Service&lt;/strong&gt; button you will be redirected to the setup page to complete the Ouvvi database setup.&lt;/p&gt;
&lt;p&gt;If you have already completed the database setup then clicking &lt;strong&gt;Start Service&lt;/strong&gt; will redirect you to the services page where you can create a new Service agent or see that your services are up and running.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/ouvvi-start-service-menu.png" alt="Start Services" title="Start Services" /&gt;&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;When using windows authentication you need to ensure you enter in the machine name to the Service User if you are not using the default NETWORKSERVICE user.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;h3 id="ouvvi-connections"&gt;Connection Library OAuth Connections&lt;/h3&gt;
&lt;p&gt;A number of the connectors and their UIs have also been extended to support OAuth, this is to ensure that you can keep connecting to the providers you need to.&lt;/p&gt;
&lt;p&gt;You can now view, edit and create OAuth connections in Ouvvi without needing to use the Data Sync designer. For a while the UI for editing certain connectors was not available, however all connector types can now be edited within the Ouvvi UI.
The connectors now supporting OAuth are: Dynamics, Salesforce, SharePoint, Podio, OData.&lt;/p&gt;
&lt;p&gt;Please note that for Dynamics, Salesforce and SharePoint connections in Ouvvi, it is limited so that only the Simego default apps can authenticate on localhost for the redirect URL. For custom apps you will need to specify the redirect URL to use your own host name. This is usually only an issue if you are exposing Ouvvi to the internet (not on localhost).&lt;/p&gt;
&lt;p&gt;If you prefer to create your connections in Data Sync then you can continue to do this, additionally you can still also upload and export connection files as normal.&lt;/p&gt;
&lt;h3 id="ipfilter"&gt;IP Filtering&lt;/h3&gt;
&lt;p&gt;Another feature now available in Ouvvi is the ability to filter access to Ouvvi by IP address.
This works for restricting access when you have exposed your Ouvvi site to the internet. You should still use an SSL certificate when exposing Ouvvi outside of the local machine.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/ouvvi-ipfilter.png" alt="IP Filter" title="IP Filter" /&gt;&lt;/p&gt;
&lt;p&gt;If an IP is not included in the list then access to Ouvvi is disabled and not possible. Users will have the message &lt;strong&gt;Access to [OUVVISITENAME] was denied&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;Note that localhost is always allowed by default to prevent being completely locked out.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/ouvvi-ipfilter-accessdenied.png" alt="Access Denied IP Filter" title="Access Denied IP Filter" /&gt;&lt;/p&gt;
&lt;p&gt;To add IP addresses to the list click onto the &lt;strong&gt;Edit&lt;/strong&gt; button and add all the IP addresses you need.&lt;/p&gt;
&lt;p&gt;We will continue working on Version 6 into the start of 2023, so if you have any comments or suggestions please send us a message and we can look at adding additional features to the new release.&lt;/p&gt;
</description>
      <source url="http://www.simego.com/blog">Team Blog</source>
      <pubDate>Wed, 07 Dec 2022 12:55:33 +0000</pubDate>
    </item>
    <item>
      <link>http://www.simego.com/blog/custom-data-connector</link>
      <author>info@simego.com (Sean Cleaver)</author>
      <title>Advanced: Building a Custom Data Sync Connector</title>
      <description>&lt;h2 id="what-is-a-custom-connector"&gt;What is a Custom Connector?&lt;/h2&gt;
&lt;p&gt;A Data Sync custom connector is compiled connector built with .NET Framework and C# and this gives you full control to build the connector and is typically used in more advanced scenarios.
Examples of custom connectors might be the SharePoint and Dynamics CRM connectors, as these are complex and not something which can be built with a simple markup description.
By building a connector for Data Sync you can leverage all of the Data Sync features, have the full debugging experience with F5 run and the ability to step through your code with Visual Studio.&lt;/p&gt;
&lt;h3 id="what-do-you-need"&gt;What do you need?&lt;/h3&gt;
&lt;p&gt;To build a custom connector you will need a licensed copy of Data Synchrionisation Studio and either Visual Studio 2022 or Rider .NET Framework Development Environment.&lt;/p&gt;
&lt;h3 id="how-do-custom-connectors-work"&gt;How do Custom Connectors work?&lt;/h3&gt;
&lt;p&gt;Custom Data Sync connectors are loaded at runtime by Data Sync and we use .NET reflection to find meta-data about the connector. After this we use the Interfaces &lt;code&gt;IDataSourceReader&lt;/code&gt; and &lt;code&gt;IDataSourceWriter&lt;/code&gt; to call methods on the connector.&lt;/p&gt;
&lt;p&gt;The classes &lt;code&gt;DataReaderProviderBase&lt;/code&gt; and &lt;code&gt;DataWriterProviderBase&lt;/code&gt; provide a quicker implementation as they handle most of the default behavior and you only need to implement a few methods.&lt;/p&gt;
&lt;p&gt;For example a basic read-only custom connector we need to implement the following methods when inheriting from &lt;code&gt;DataReaderProviderBase&lt;/code&gt;: GetDefaultDataSchema, GetDataTable, GetInitializationParameters and Initialize methods.&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;code&gt;GetDefaultDataSchema&lt;/code&gt; - return the schema for the connector i.e. the columns and data types for the table.&lt;/li&gt;
&lt;li&gt;&lt;code&gt;GetDataTable&lt;/code&gt; - return a table of data based on the configured &lt;code&gt;SchemaMap&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;&lt;code&gt;GetInitializationParameters&lt;/code&gt; - return a list of configuration parameters to save in the project file.&lt;/li&gt;
&lt;li&gt;&lt;code&gt;Initialize&lt;/code&gt; - Load the connector configuration from a list of parameters stored in the project file.&lt;/li&gt;
&lt;/ul&gt;
&lt;h2 id="building-a-basic-data-sync-connector"&gt;Building a basic Data Sync connector&lt;/h2&gt;
&lt;p&gt;In the example below we create a basic custom connector that downloads currency exchange rates from &lt;a href="https://open.er-api.com/v6/latest/USD"&gt;https://open.er-api.com/v6/latest/USD&lt;/a&gt; and converts the results in to a DataTable with the columns CCY and RATE.&lt;/p&gt;
&lt;p&gt;First we define a configuration property for the Url we need to call. Public properties exposed on the class will be shown in the Data Sync property grid.&lt;/p&gt;
&lt;div class="lang-csharp editor-colors"&gt;&lt;div style="color:Black;background-color:White;"&gt;&lt;pre&gt;
&lt;span style="color:Blue;"&gt;public&lt;/span&gt; &lt;span style="color:Blue;"&gt;string&lt;/span&gt; ServiceUrl { &lt;span style="color:Blue;"&gt;get&lt;/span&gt;; &lt;span style="color:Blue;"&gt;set&lt;/span&gt;; } = &lt;span style="color:#A31515;"&gt;&amp;quot;https://open.er-api.com/v6/latest/USD&amp;quot;&lt;/span&gt;;
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;p&gt;Next we have methods to Load and Save the configuration properties so we can save the project. &lt;code&gt;Initialize&lt;/code&gt; is called to load the configuration and &lt;code&gt;GetInitializationParameters&lt;/code&gt; is called to save the configuration.&lt;/p&gt;
&lt;div class="lang-csharp editor-colors"&gt;&lt;div style="color:Black;background-color:White;"&gt;&lt;pre&gt;
&lt;span style="color:Green;"&gt;//Load the Provider Settings from the File.&lt;/span&gt;
&lt;span style="color:Blue;"&gt;public&lt;/span&gt; &lt;span style="color:Blue;"&gt;override&lt;/span&gt; &lt;span style="color:Blue;"&gt;void&lt;/span&gt; Initialize(List&amp;lt;ProviderParameter&amp;gt; parameters)
{
    &lt;span style="color:Blue;"&gt;foreach&lt;/span&gt; (ProviderParameter p &lt;span style="color:Blue;"&gt;in&lt;/span&gt; parameters)
    {               
        &lt;span style="color:Blue;"&gt;if&lt;/span&gt;(p.Name == nameof(ServiceUrl))
        {
            ServiceUrl = p.Value;
        }               
    }
}       
        
&lt;span style="color:Green;"&gt;//Return the Provider Settings so we can save the Project File.&lt;/span&gt;
&lt;span style="color:Blue;"&gt;public&lt;/span&gt; &lt;span style="color:Blue;"&gt;override&lt;/span&gt; List&amp;lt;ProviderParameter&amp;gt; GetInitializationParameters()
{
    &lt;span style="color:Blue;"&gt;return&lt;/span&gt; &lt;span style="color:Blue;"&gt;new&lt;/span&gt; List&amp;lt;ProviderParameter&amp;gt;
                {
                    &lt;span style="color:Blue;"&gt;new&lt;/span&gt; ProviderParameter(nameof(ServiceUrl), ServiceUrl)
                };
}
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;p&gt;Then we need to let Data Sync know what columns this data source exposes. In &lt;code&gt;GetDefaultDataSchema&lt;/code&gt; we return a &lt;code&gt;DataSchema&lt;/code&gt; object with a list of columns in the &lt;code&gt;Map&lt;/code&gt; property which represents the data source schema.&lt;/p&gt;
&lt;div class="lang-csharp editor-colors"&gt;&lt;div style="color:Black;background-color:White;"&gt;&lt;pre&gt;
&lt;span style="color:Green;"&gt;//Return the Data source default Schema.&lt;/span&gt;
&lt;span style="color:Blue;"&gt;public&lt;/span&gt; &lt;span style="color:Blue;"&gt;override&lt;/span&gt; DataSchema GetDefaultDataSchema()
{        
    DataSchema schema = &lt;span style="color:Blue;"&gt;new&lt;/span&gt; DataSchema();

    schema.Map.Add(&lt;span style="color:Blue;"&gt;new&lt;/span&gt; DataSchemaItem(&lt;span style="color:#A31515;"&gt;&amp;quot;CCY&amp;quot;&lt;/span&gt;, &lt;span style="color:Blue;"&gt;typeof&lt;/span&gt;(&lt;span style="color:Blue;"&gt;string&lt;/span&gt;), &lt;span style="color:Blue;"&gt;true&lt;/span&gt;, &lt;span style="color:Blue;"&gt;false&lt;/span&gt;, &lt;span style="color:Blue;"&gt;false&lt;/span&gt;, 3));
    schema.Map.Add(&lt;span style="color:Blue;"&gt;new&lt;/span&gt; DataSchemaItem(&lt;span style="color:#A31515;"&gt;&amp;quot;RATE&amp;quot;&lt;/span&gt;, &lt;span style="color:Blue;"&gt;typeof&lt;/span&gt;(&lt;span style="color:Blue;"&gt;decimal&lt;/span&gt;), &lt;span style="color:Blue;"&gt;false&lt;/span&gt;, &lt;span style="color:Blue;"&gt;false&lt;/span&gt;, &lt;span style="color:Blue;"&gt;false&lt;/span&gt;, -1));
            
    &lt;span style="color:Blue;"&gt;return&lt;/span&gt; schema;
}
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;p&gt;Finally we need to return the data by filling the passed DataTable (dt) with rows based on the configured SchemaMap.&lt;/p&gt;
&lt;p&gt;The SchemaMap defines a column mapping of &lt;strong&gt;ColumnA -&amp;gt; ColumnName &amp;lt;- ColumnB&lt;/strong&gt;, therefore depending which side your connected to the map can be different.
We can use &lt;code&gt;DataSchemaMapping&lt;/code&gt; to help with this column mapping to map columns to the source name.
Further to this by using a callback function on the &lt;code&gt;dt.Rows.Add&lt;/code&gt; method we can make it easier by just returning the column value for each column asked for in the callback.&lt;/p&gt;
&lt;div class="lang-csharp editor-colors"&gt;&lt;div style="color:Black;background-color:White;"&gt;&lt;pre&gt;
&lt;span style="color:Green;"&gt;// Return Table of Results.&lt;/span&gt;
&lt;span style="color:Blue;"&gt;public&lt;/span&gt; &lt;span style="color:Blue;"&gt;override&lt;/span&gt; DataTableStore GetDataTable(DataTableStore dt)
{                                    
    &lt;span style="color:Blue;"&gt;var&lt;/span&gt; helper = &lt;span style="color:Blue;"&gt;new&lt;/span&gt; HttpWebRequestHelper();
    &lt;span style="color:Blue;"&gt;var&lt;/span&gt; response = helper.GetRequestAsJson(ServiceUrl);

    &lt;span style="color:Blue;"&gt;var&lt;/span&gt; mapping = &lt;span style="color:Blue;"&gt;new&lt;/span&gt; DataSchemaMapping(SchemaMap, Side);
    &lt;span style="color:Blue;"&gt;var&lt;/span&gt; columns = SchemaMap.GetIncludedColumns();
            
    &lt;span style="color:Green;"&gt;//Loop around your data adding it to the DataTableStore dt object.&lt;/span&gt;
    &lt;span style="color:Blue;"&gt;foreach&lt;/span&gt; (JProperty item_row &lt;span style="color:Blue;"&gt;in&lt;/span&gt; response[&lt;span style="color:#A31515;"&gt;&amp;quot;rates&amp;quot;&lt;/span&gt;])
    {                
        dt.Rows.Add(mapping, columns,
            (item, columnName) =&amp;gt;
            {
                &lt;span style="color:Blue;"&gt;if&lt;/span&gt; (columnName == &lt;span style="color:#A31515;"&gt;&amp;quot;CCY&amp;quot;&lt;/span&gt;) &lt;span style="color:Blue;"&gt;return&lt;/span&gt; item_row.Name;
                &lt;span style="color:Blue;"&gt;if&lt;/span&gt; (columnName == &lt;span style="color:#A31515;"&gt;&amp;quot;RATE&amp;quot;&lt;/span&gt;) &lt;span style="color:Blue;"&gt;return&lt;/span&gt; item_row.ToObject&amp;lt;&lt;span style="color:Blue;"&gt;decimal&lt;/span&gt;&amp;gt;();
                &lt;span style="color:Blue;"&gt;return&lt;/span&gt; &lt;span style="color:Blue;"&gt;null&lt;/span&gt;;
            });
    }
            
    &lt;span style="color:Blue;"&gt;return&lt;/span&gt; dt;
}
 
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;h3 id="putting-it-all-together"&gt;Putting it all together&lt;/h3&gt;
&lt;p&gt;If we put all this together in a Data Connector class it would look like this.&lt;/p&gt;
&lt;div class="lang-csharp editor-colors"&gt;&lt;div style="color:Black;background-color:White;"&gt;&lt;pre&gt;
&lt;span style="color:Blue;"&gt;using&lt;/span&gt; Newtonsoft.Json.Linq;
&lt;span style="color:Blue;"&gt;using&lt;/span&gt; Simego.DataSync;
&lt;span style="color:Blue;"&gt;using&lt;/span&gt; Simego.DataSync.Providers;
&lt;span style="color:Blue;"&gt;using&lt;/span&gt; System.Collections.Generic;

&lt;span style="color:Blue;"&gt;namespace&lt;/span&gt; ExampleConnector
{
    [ProviderInfo(Name = &lt;span style="color:#A31515;"&gt;&amp;quot;ExampleConnector&amp;quot;&lt;/span&gt;, Description = &lt;span style="color:#A31515;"&gt;&amp;quot;ExampleConnector Description&amp;quot;&lt;/span&gt;)]
    &lt;span style="color:Blue;"&gt;public&lt;/span&gt; &lt;span style="color:Blue;"&gt;class&lt;/span&gt; ExampleConnectorDatasourceReader : DataReaderProviderBase
    {
        &lt;span style="color:Blue;"&gt;public&lt;/span&gt; &lt;span style="color:Blue;"&gt;string&lt;/span&gt; ServiceUrl { &lt;span style="color:Blue;"&gt;get&lt;/span&gt;; &lt;span style="color:Blue;"&gt;set&lt;/span&gt;; } = &lt;span style="color:#A31515;"&gt;&amp;quot;https://open.er-api.com/v6/latest/USD&amp;quot;&lt;/span&gt;;

        &lt;span style="color:Green;"&gt;// Return Table of Results.&lt;/span&gt;
        &lt;span style="color:Blue;"&gt;public&lt;/span&gt; &lt;span style="color:Blue;"&gt;override&lt;/span&gt; DataTableStore GetDataTable(DataTableStore dt)
        {                                    
            &lt;span style="color:Blue;"&gt;var&lt;/span&gt; helper = &lt;span style="color:Blue;"&gt;new&lt;/span&gt; HttpWebRequestHelper();
            &lt;span style="color:Blue;"&gt;var&lt;/span&gt; response = helper.GetRequestAsJson(ServiceUrl);

            &lt;span style="color:Blue;"&gt;var&lt;/span&gt; mapping = &lt;span style="color:Blue;"&gt;new&lt;/span&gt; DataSchemaMapping(SchemaMap, Side);
            &lt;span style="color:Blue;"&gt;var&lt;/span&gt; columns = SchemaMap.GetIncludedColumns();
            
            &lt;span style="color:Green;"&gt;//Loop around your data adding it to the DataTableStore dt object.&lt;/span&gt;
            &lt;span style="color:Blue;"&gt;foreach&lt;/span&gt; (JProperty item_row &lt;span style="color:Blue;"&gt;in&lt;/span&gt; response[&lt;span style="color:#A31515;"&gt;&amp;quot;rates&amp;quot;&lt;/span&gt;])
            {                
                dt.Rows.Add(mapping, columns,
                    (item, columnName) =&amp;gt;
                    {
                        &lt;span style="color:Blue;"&gt;if&lt;/span&gt; (columnName == &lt;span style="color:#A31515;"&gt;&amp;quot;CCY&amp;quot;&lt;/span&gt;) &lt;span style="color:Blue;"&gt;return&lt;/span&gt; item_row.Name;
                        &lt;span style="color:Blue;"&gt;if&lt;/span&gt; (columnName == &lt;span style="color:#A31515;"&gt;&amp;quot;RATE&amp;quot;&lt;/span&gt;) &lt;span style="color:Blue;"&gt;return&lt;/span&gt; item_row.ToObject&amp;lt;&lt;span style="color:Blue;"&gt;decimal&lt;/span&gt;&amp;gt;();
                        &lt;span style="color:Blue;"&gt;return&lt;/span&gt; &lt;span style="color:Blue;"&gt;null&lt;/span&gt;;
                    });
            }
            
            &lt;span style="color:Blue;"&gt;return&lt;/span&gt; dt;
        }
        
        &lt;span style="color:Green;"&gt;//Return the Data source default Schema.&lt;/span&gt;
        &lt;span style="color:Blue;"&gt;public&lt;/span&gt; &lt;span style="color:Blue;"&gt;override&lt;/span&gt; DataSchema GetDefaultDataSchema()
        {        
            DataSchema schema = &lt;span style="color:Blue;"&gt;new&lt;/span&gt; DataSchema();

            schema.Map.Add(&lt;span style="color:Blue;"&gt;new&lt;/span&gt; DataSchemaItem(&lt;span style="color:#A31515;"&gt;&amp;quot;CCY&amp;quot;&lt;/span&gt;, &lt;span style="color:Blue;"&gt;typeof&lt;/span&gt;(&lt;span style="color:Blue;"&gt;string&lt;/span&gt;), &lt;span style="color:Blue;"&gt;true&lt;/span&gt;, &lt;span style="color:Blue;"&gt;false&lt;/span&gt;, &lt;span style="color:Blue;"&gt;false&lt;/span&gt;, 3));
            schema.Map.Add(&lt;span style="color:Blue;"&gt;new&lt;/span&gt; DataSchemaItem(&lt;span style="color:#A31515;"&gt;&amp;quot;RATE&amp;quot;&lt;/span&gt;, &lt;span style="color:Blue;"&gt;typeof&lt;/span&gt;(&lt;span style="color:Blue;"&gt;decimal&lt;/span&gt;), &lt;span style="color:Blue;"&gt;false&lt;/span&gt;, &lt;span style="color:Blue;"&gt;false&lt;/span&gt;, &lt;span style="color:Blue;"&gt;false&lt;/span&gt;, -1));
            
            &lt;span style="color:Blue;"&gt;return&lt;/span&gt; schema;
        }

        &lt;span style="color:Green;"&gt;//Return the Provider Settings so we can save the Project File.&lt;/span&gt;
        &lt;span style="color:Blue;"&gt;public&lt;/span&gt; &lt;span style="color:Blue;"&gt;override&lt;/span&gt; List&amp;lt;ProviderParameter&amp;gt; GetInitializationParameters()
        {
            &lt;span style="color:Blue;"&gt;return&lt;/span&gt; &lt;span style="color:Blue;"&gt;new&lt;/span&gt; List&amp;lt;ProviderParameter&amp;gt;
                       {
                            &lt;span style="color:Blue;"&gt;new&lt;/span&gt; ProviderParameter(nameof(ServiceUrl), ServiceUrl)
                       };
        }

        &lt;span style="color:Green;"&gt;//Load the Provider Settings from the File.&lt;/span&gt;
        &lt;span style="color:Blue;"&gt;public&lt;/span&gt; &lt;span style="color:Blue;"&gt;override&lt;/span&gt; &lt;span style="color:Blue;"&gt;void&lt;/span&gt; Initialize(List&amp;lt;ProviderParameter&amp;gt; parameters)
        {
            &lt;span style="color:Blue;"&gt;foreach&lt;/span&gt; (ProviderParameter p &lt;span style="color:Blue;"&gt;in&lt;/span&gt; parameters)
            {               
                &lt;span style="color:Blue;"&gt;if&lt;/span&gt;(p.Name == nameof(ServiceUrl))
                {
                    ServiceUrl = p.Value;
                }               
            }
        }        
    }
}
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;h3 id="example-connector-loaded-in-the-data-sync-designer"&gt;Example Connector loaded in the Data Sync Designer&lt;/h3&gt;
&lt;p&gt;Once this has been built and loaded into Data Sync, you can build a project to use it like the image below.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/custom-connector-example-connector.png" alt="Custom Connector Open in Data Sync Designer" /&gt;&lt;/p&gt;
&lt;h2 id="getting-started"&gt;Getting Started&lt;/h2&gt;
&lt;p&gt;To get started with your own connector we have created a function in DataSync to create a default project for you. To get to this go to &lt;strong&gt;Tools &amp;gt; Create Data Provider VS Project&lt;/strong&gt;, which will open a window where you can define the assembly name and output path.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/custom-connector-create-vs-project.png" alt="Create Data Provider VS Project" /&gt;&lt;/p&gt;
&lt;p&gt;Clicking OK will create a Visual Studio Project for a new connector configured ready to start your development.&lt;/p&gt;
&lt;p&gt;For connector development you need a reference to &lt;code&gt;Simego.DataSync.Core.dll&lt;/code&gt; from the Data Sync install directory and if your going to use the &lt;code&gt;HttpWebRequestHelper&lt;/code&gt; you will also need to add a Nuget package reference to &lt;code&gt;Newtonsoft.Json&lt;/code&gt; version 13.0.3.&lt;/p&gt;
&lt;p&gt;To be able to debug your project in Visual Studio the project needs to be configured to start an external program which is the Data Sync Designer from the install directory i.e. &lt;code&gt;&amp;quot;C:\Program Files\Simego\Data Synchronisation Studio 6.0\Simego.DataSync.Studio.exe&amp;quot;&lt;/code&gt; and you need to pass the command line parameter &lt;code&gt;-debug&lt;/code&gt;.&lt;/p&gt;
&lt;p&gt;When you run your project from Visual Studio it will start Data Sync and Data Sync will look in the Visual Studio output directory for connectors and load them from the folder ready to debug your code.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/custom-connector-vs-project.png" alt="Data Provider VS Project" /&gt;&lt;/p&gt;
&lt;h2 id="identifier-columns"&gt;Identifier Columns&lt;/h2&gt;
&lt;p&gt;The first concept to understand is the role of the Identifier Column with Data Sync connectors. These values are attached to the row internally within Data Sync and are a way to maintain the data source PrimaryKey even when its not part of the Schema Map. By maintaining this Identifier Column value it makes it easier to handle UPDATE/DELETE actions on the target by the PrimaryKey value.&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;If your connector is going to be read-only then Identifier Columns are not necessary.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;During the call to &lt;code&gt;GetDataTable&lt;/code&gt; you can add Identifier Columns once only. After you add Identifier Columns you must add the rows to the Data Table with the method call &lt;code&gt;AddWithIdentifier&lt;/code&gt;&lt;/p&gt;
&lt;div class="lang-csharp editor-colors"&gt;&lt;div style="color:Black;background-color:White;"&gt;&lt;pre&gt;
&lt;span style="color:Blue;"&gt;public&lt;/span&gt; &lt;span style="color:Blue;"&gt;override&lt;/span&gt; DataTableStore GetDataTable(DataTableStore dt)
{            
    &lt;span style="color:Green;"&gt;//This data source has a single integer ID value we use this to store the ID to assist with UPDATE and DELETE actions.&lt;/span&gt;
    dt.AddIdentifierColumn(&lt;span style="color:Blue;"&gt;typeof&lt;/span&gt;(&lt;span style="color:Blue;"&gt;int&lt;/span&gt;));
            
    &lt;span style="color:Blue;"&gt;var&lt;/span&gt; mapping = &lt;span style="color:Blue;"&gt;new&lt;/span&gt; DataSchemaMapping(SchemaMap, Side);
    &lt;span style="color:Blue;"&gt;var&lt;/span&gt; columns = SchemaMap.GetIncludedColumns();

    &lt;span style="color:Green;"&gt;// Returns a basic Dictionary with some data you would replace this with calls to your target system to get the data.&lt;/span&gt;
    &lt;span style="color:Blue;"&gt;var&lt;/span&gt; result = TestData();

    &lt;span style="color:Green;"&gt;//Loop around your data adding it to the DataTableStore dt object.&lt;/span&gt;
    &lt;span style="color:Blue;"&gt;foreach&lt;/span&gt; (&lt;span style="color:Blue;"&gt;var&lt;/span&gt; item_row &lt;span style="color:Blue;"&gt;in&lt;/span&gt; result)
    {
        dt.Rows.AddWithIdentifier(mapping, columns,
            (item, columnName) =&amp;gt;
            {
                &lt;span style="color:Blue;"&gt;return&lt;/span&gt; item_row[columnName];
            }
            , item_row[&lt;span style="color:#A31515;"&gt;&amp;quot;item_id&amp;quot;&lt;/span&gt;]);
    }
            
    &lt;span style="color:Blue;"&gt;return&lt;/span&gt; dt;
}
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;p&gt;Now within your writer class it is easy to get the identifier value for a row to be used with UPDATE and DELETE actions.&lt;/p&gt;
&lt;h2 id="custom-configuration-ui"&gt;Custom Configuration UI&lt;/h2&gt;
&lt;p&gt;You can provide a custom UI component to be displayed in the Data Sync connection dialog. This is used to assist in creating the connection and is especially useful if you need to guide the user or choose different data sources to connect to.&lt;/p&gt;
&lt;p&gt;To use a custom UI component your connector must implement the &lt;code&gt;IDataSourceSetup&lt;/code&gt; interface.&lt;/p&gt;
&lt;div class="lang-csharp editor-colors"&gt;&lt;div style="color:Black;background-color:White;"&gt;&lt;pre&gt;
&lt;span style="color:Blue;"&gt;public&lt;/span&gt; &lt;span style="color:Blue;"&gt;interface&lt;/span&gt; IDataSourceSetup
{
    &lt;span style="color:Blue;"&gt;void&lt;/span&gt; DisplayConfigurationUI(IntPtr parentHwnd);
    IDataSourceReader GetReader();
    &lt;span style="color:Blue;"&gt;bool&lt;/span&gt; Validate();
}
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;ul&gt;
&lt;li&gt;&lt;code&gt;DisplayConfigurationUI&lt;/code&gt; is called when we show the UI component it will pass a handle to the parent window where you can add your control.&lt;/li&gt;
&lt;li&gt;&lt;code&gt;Validate()&lt;/code&gt; is called when the user clicks the &lt;strong&gt;OK&lt;/strong&gt; button in the connection dialog. Here you can throw an exception to the user or return true to the accept the configuration settings.&lt;/li&gt;
&lt;li&gt;&lt;code&gt;GetReader()&lt;/code&gt; is then called to return an instance of the configured DataSource Reader. Typically this is just &lt;code&gt;this&lt;/code&gt;.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;Below is an example which loads a &lt;code&gt;ConnectionInterface&lt;/code&gt; form which contains a &lt;code&gt;PropertyGrid&lt;/code&gt; control, and is then loaded into the connection dialog.&lt;/p&gt;
&lt;div class="lang-csharp editor-colors"&gt;&lt;div style="color:Black;background-color:White;"&gt;&lt;pre&gt;
&lt;span style="color:Blue;"&gt;public&lt;/span&gt; &lt;span style="color:Blue;"&gt;void&lt;/span&gt; DisplayConfigurationUI(IntPtr parent)
{
    &lt;span style="color:Blue;"&gt;var&lt;/span&gt; parentControl = Control.FromHandle(parent);

    &lt;span style="color:Blue;"&gt;if&lt;/span&gt; (_connectionIf == &lt;span style="color:Blue;"&gt;null&lt;/span&gt;)
    {
        _connectionIf = &lt;span style="color:Blue;"&gt;new&lt;/span&gt; ConnectionInterface();
        _connectionIf.PropertyGrid.SelectedObject = &lt;span style="color:Blue;"&gt;new&lt;/span&gt; ConnectionProperties(&lt;span style="color:Blue;"&gt;this&lt;/span&gt;);
    }

    _connectionIf.Font = parentControl.Font;
    _connectionIf.Size = &lt;span style="color:Blue;"&gt;new&lt;/span&gt; Size(parentControl.Width, parentControl.Height);
    _connectionIf.Location = &lt;span style="color:Blue;"&gt;new&lt;/span&gt; Point(0, 0);
    _connectionIf.Dock = DockStyle.Fill;

    parentControl.Controls.Add(_connectionIf);
}

&lt;span style="color:Blue;"&gt;public&lt;/span&gt; &lt;span style="color:Blue;"&gt;bool&lt;/span&gt; Validate() =&amp;gt; &lt;span style="color:Blue;"&gt;true&lt;/span&gt;;
        
&lt;span style="color:Blue;"&gt;public&lt;/span&gt; IDataSourceReader GetReader() =&amp;gt; &lt;span style="color:Blue;"&gt;this&lt;/span&gt;;
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;p&gt;The &lt;code&gt;ConnectionProperties&lt;/code&gt; class is used here to create a wrapper around the reader object to expose the configuration properties to display in the &lt;code&gt;PropertyGrid&lt;/code&gt; control.&lt;/p&gt;
&lt;div class="lang-csharp editor-colors"&gt;&lt;div style="color:Black;background-color:White;"&gt;&lt;pre&gt;
&lt;span style="color:Blue;"&gt;class&lt;/span&gt; ConnectionProperties
{
    &lt;span style="color:Blue;"&gt;private&lt;/span&gt; &lt;span style="color:Blue;"&gt;readonly&lt;/span&gt; ExampleDatasourceReader _reader;
        
    [Category(&lt;span style="color:#A31515;"&gt;&amp;quot;Settings&amp;quot;&lt;/span&gt;)]
    &lt;span style="color:Blue;"&gt;public&lt;/span&gt; &lt;span style="color:Blue;"&gt;string&lt;/span&gt; ExampleSetting { &lt;span style="color:Blue;"&gt;get&lt;/span&gt; { &lt;span style="color:Blue;"&gt;return&lt;/span&gt; _reader.ExampleSetting; } &lt;span style="color:Blue;"&gt;set&lt;/span&gt; { _reader.ExampleSetting = value; } }

    &lt;span style="color:Blue;"&gt;public&lt;/span&gt; ConnectionProperties(ExampleDatasourceReader reader)
    {
        _reader = reader;
    }        
}
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;h2 id="lookups"&gt;Lookups&lt;/h2&gt;
&lt;p&gt;To support Lookup functions (LOOKUPA and LOOKUPB) in Data Sync you need to implement the interface &lt;code&gt;IDataSourceLookup&lt;/code&gt;. This requires that you return a DataTable of results based on the Lookup configuration.&lt;/p&gt;
&lt;div class="lang-csharp editor-colors"&gt;&lt;div style="color:Black;background-color:White;"&gt;&lt;pre&gt;
&lt;span style="color:Blue;"&gt;public&lt;/span&gt; &lt;span style="color:Blue;"&gt;interface&lt;/span&gt; IDataSourceLookup
{
    DataTableStore GetLookupTable(DataLookupSource source, List&amp;lt;&lt;span style="color:Blue;"&gt;string&lt;/span&gt;&amp;gt; columns);
}
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;p&gt;Here is an example of a Lookup implementation. This method would be called when a user uses calculated columns with an expression like this.&lt;/p&gt;
&lt;div class="lang-csharp editor-colors"&gt;&lt;div style="color:Black;background-color:White;"&gt;&lt;pre&gt;
LOOKUPA(&lt;span style="color:#A31515;"&gt;&amp;quot;supplierid&amp;quot;&lt;/span&gt;, &lt;span style="color:#A31515;"&gt;&amp;quot;suppliers&amp;quot;&lt;/span&gt;, WHEN(&lt;span style="color:#A31515;"&gt;&amp;quot;companyname&amp;quot;&lt;/span&gt;, value))
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;p&gt;What you do is create a new instance of your connector and set the appropriate properties from your current instance. In this case we need to copy the database connection string.
&lt;code&gt;DataLookupSource&lt;/code&gt; contains parameters passed by the user. So really in the example below we are looking to change the SourceTable property to the name passed in the source (suppliers).&lt;/p&gt;
&lt;p&gt;You then create a default schema map including only the columns from the columns list (&amp;quot;supplierid&amp;quot;, &amp;quot;companyname&amp;quot;) and fill and return the DataTable.&lt;/p&gt;
&lt;div class="lang-csharp editor-colors"&gt;&lt;div style="color:Black;background-color:White;"&gt;&lt;pre&gt;
&lt;span style="color:Blue;"&gt;public&lt;/span&gt; DataTableStore GetLookupTable(DataLookupSource source, List&amp;lt;&lt;span style="color:Blue;"&gt;string&lt;/span&gt;&amp;gt; columns)
{
    &lt;span style="color:Blue;"&gt;var&lt;/span&gt; reader = &lt;span style="color:Blue;"&gt;new&lt;/span&gt; SqlDataSourceReader
                        {
                            ConnectionString = ConnectionString,
                            CommandTimeout = CommandTimeout,
                            SourceTable = source.Config.ContainsKey(&lt;span style="color:#A31515;"&gt;&amp;quot;SourceTable&amp;quot;&lt;/span&gt;) ? source.Config[&lt;span style="color:#A31515;"&gt;&amp;quot;SourceTable&amp;quot;&lt;/span&gt;] : source.Name
                        };

    reader.Initialize(SecurityService);

    &lt;span style="color:Blue;"&gt;var&lt;/span&gt; defaultSchema = reader.GetDefaultDataSchema();
    reader.SchemaMap = &lt;span style="color:Blue;"&gt;new&lt;/span&gt; DataSchema();

    &lt;span style="color:Blue;"&gt;foreach&lt;/span&gt; (&lt;span style="color:Blue;"&gt;var&lt;/span&gt; dsi &lt;span style="color:Blue;"&gt;in&lt;/span&gt; defaultSchema.Map)
    {
        &lt;span style="color:Blue;"&gt;foreach&lt;/span&gt; (&lt;span style="color:Blue;"&gt;var&lt;/span&gt; column &lt;span style="color:Blue;"&gt;in&lt;/span&gt; columns)
        {
            &lt;span style="color:Blue;"&gt;if&lt;/span&gt; ( dsi.ColumnName.Equals(column, StringComparison.OrdinalIgnoreCase))
                reader.SchemaMap.Map.Add(dsi.Copy());
        }
    }

    &lt;span style="color:Blue;"&gt;return&lt;/span&gt; reader.GetDataTable();
}
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;h2 id="connection-library"&gt;Connection Library&lt;/h2&gt;
&lt;p&gt;The connection library is used to store connection configuration which can be updated to maintain the connection. This is typically endpoints, username and passwords.
These are then stored separate from the project file in either the local library on disk or the Ouvvi library in the Ouvvi database.&lt;/p&gt;
&lt;p&gt;To support the connection library you need to implement the interface &lt;code&gt;IDataSourceRegistry&lt;/code&gt;&lt;/p&gt;
&lt;div class="lang-csharp editor-colors"&gt;&lt;div style="color:Black;background-color:White;"&gt;&lt;pre&gt;
&lt;span style="color:Blue;"&gt;public&lt;/span&gt; &lt;span style="color:Blue;"&gt;interface&lt;/span&gt; IDataSourceRegistry
{
    &lt;span style="color:Blue;"&gt;string&lt;/span&gt; RegistryKey { &lt;span style="color:Blue;"&gt;get&lt;/span&gt;; &lt;span style="color:Blue;"&gt;set&lt;/span&gt;; }        
    &lt;span style="color:Blue;"&gt;void&lt;/span&gt; InitializeFromRegistry(IDataSourceRegistryProvider provider);
    List&amp;lt;ProviderParameter&amp;gt; GetRegistryInitializationParameters();
    &lt;span style="color:Blue;"&gt;object&lt;/span&gt; GetRegistryInterface();
}
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;ul&gt;
&lt;li&gt;&lt;code&gt;RegistryKey&lt;/code&gt; - The name of the connection library entry. This must be managed by the default methods &lt;code&gt;Initialize&lt;/code&gt; and &lt;code&gt;GetInitializationParameters&lt;/code&gt; so that this key is set during project load and saved when you save the project.&lt;/li&gt;
&lt;li&gt;&lt;code&gt;InitializeFromRegistry&lt;/code&gt; - Used to Initialize your connector from settings stored in the connection library.&lt;/li&gt;
&lt;li&gt;&lt;code&gt;GetRegistryInitializationParameters&lt;/code&gt; - Returns the connection parameters to store in the connection library.&lt;/li&gt;
&lt;li&gt;&lt;code&gt;GetRegistryInterface&lt;/code&gt; - Returns a version of the connector where you can hide the connection library parameters from the default Data Sync UI.&lt;/li&gt;
&lt;/ul&gt;
&lt;div class="lang-csharp editor-colors"&gt;&lt;div style="color:Black;background-color:White;"&gt;&lt;pre&gt;
&lt;span style="color:Blue;"&gt;public&lt;/span&gt; &lt;span style="color:Blue;"&gt;void&lt;/span&gt; InitializeFromRegistry(IDataSourceRegistryProvider provider)
{
    &lt;span style="color:Blue;"&gt;var&lt;/span&gt; registry = provider.Get(RegistryKey);
    &lt;span style="color:Blue;"&gt;if&lt;/span&gt; (registry != &lt;span style="color:Blue;"&gt;null&lt;/span&gt;)
    {
        &lt;span style="color:Blue;"&gt;foreach&lt;/span&gt; (ProviderParameter p &lt;span style="color:Blue;"&gt;in&lt;/span&gt; registry.Parameters)
        {
            &lt;span style="color:Blue;"&gt;if&lt;/span&gt;(p.Name == nameof(ServiceUrl))
            {
                ServiceUrl = p.Value;
            }  
        }
    }
}
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;blockquote&gt;
&lt;p&gt;&lt;strong&gt;TIP:&lt;/strong&gt; If you need to update the connection library at runtime, save a reference to the &lt;code&gt;IDataSourceRegistryProvider&lt;/code&gt; so you can write back to the library later.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;div class="lang-csharp editor-colors"&gt;&lt;div style="color:Black;background-color:White;"&gt;&lt;pre&gt;
&lt;span style="color:Blue;"&gt;public&lt;/span&gt; List&amp;lt;ProviderParameter&amp;gt; GetRegistryInitializationParameters()
{
    &lt;span style="color:Blue;"&gt;return&lt;/span&gt; &lt;span style="color:Blue;"&gt;new&lt;/span&gt; List&amp;lt;ProviderParameter&amp;gt;
                {
                    &lt;span style="color:Blue;"&gt;new&lt;/span&gt; ProviderParameter(nameof(ServiceUrl), ServiceUrl)
                };
            
}
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;p&gt;&lt;code&gt;GetRegistryInterface&lt;/code&gt; requires a new class which wraps your connector to expose only those parameters which can be changed.
For example you can use the helper base class &lt;code&gt;DataReaderRegistryView&amp;lt;T&amp;gt;&lt;/code&gt; and then add the properties to the class you want to be available in the data source property grid like this.&lt;/p&gt;
&lt;div class="lang-csharp editor-colors"&gt;&lt;div style="color:Black;background-color:White;"&gt;&lt;pre&gt;
&lt;span style="color:Blue;"&gt;public&lt;/span&gt; &lt;span style="color:Blue;"&gt;class&lt;/span&gt; ExampleConnectorDatasourceReaderWithRegistry : DataReaderRegistryView&amp;lt;ExampleConnectorDatasourceReader&amp;gt;
{
    [ReadOnly(&lt;span style="color:Blue;"&gt;true&lt;/span&gt;)]
    &lt;span style="color:Blue;"&gt;public&lt;/span&gt; &lt;span style="color:Blue;"&gt;string&lt;/span&gt; ServiceUrl =&amp;gt; _reader.ServiceUrl;

    &lt;span style="color:Blue;"&gt;public&lt;/span&gt; ExampleConnectorDatasourceReaderWithRegistry(ExampleConnectorDatasourceReader reader) : &lt;span style="color:Blue;"&gt;base&lt;/span&gt;(reader)
    {
            
    }
}
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;p&gt;Then return and instance of this class on a call to &lt;code&gt;GetRegistryInterface&lt;/code&gt;.&lt;/p&gt;
&lt;div class="lang-csharp editor-colors"&gt;&lt;div style="color:Black;background-color:White;"&gt;&lt;pre&gt;
&lt;span style="color:Blue;"&gt;object&lt;/span&gt; GetRegistryInterface() =&amp;gt; &lt;span style="color:Blue;"&gt;new&lt;/span&gt; ExampleConnectorDatasourceReaderWithRegistry(&lt;span style="color:Blue;"&gt;this&lt;/span&gt;);
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;h2 id="connection-library-server-explorer"&gt;Connection Library Server Explorer&lt;/h2&gt;
&lt;p&gt;If your connector can return multiple data sources i.e Tables in a Database then you can implement the Connection Library Server Explorer. This allows for quick connection directly from the TreeView and lists the available data sources.&lt;/p&gt;
&lt;p&gt;To do this you need to implement the &lt;code&gt;IDataSourceRegistryView&lt;/code&gt; interface.&lt;/p&gt;
&lt;div class="lang-csharp editor-colors"&gt;&lt;div style="color:Black;background-color:White;"&gt;&lt;pre&gt;
&lt;span style="color:Blue;"&gt;public&lt;/span&gt; &lt;span style="color:Blue;"&gt;interface&lt;/span&gt; IDataSourceRegistryView
{
    RegistryConnectionInfo GetRegistryConnectionInfo();
    RegistryViewContainer GetRegistryViewContainer(&lt;span style="color:Blue;"&gt;string&lt;/span&gt; parent, &lt;span style="color:Blue;"&gt;string&lt;/span&gt; id, &lt;span style="color:Blue;"&gt;object&lt;/span&gt; state);
    &lt;span style="color:Blue;"&gt;object&lt;/span&gt; GetRegistryViewConfigurationInterface();
}
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;ul&gt;
&lt;li&gt;&lt;code&gt;GetRegistryConnectionInfo&lt;/code&gt; - returns meta data about this connection i.e name and icon.&lt;/li&gt;
&lt;li&gt;&lt;code&gt;GetRegistryViewContainer&lt;/code&gt; - return the Folder and items list to display in the TreeView.&lt;/li&gt;
&lt;li&gt;&lt;code&gt;GetRegistryViewConfigurationInterface&lt;/code&gt; - currently unused and should return null.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;Below is a simple implementation of the &lt;code&gt;IDataSourceRegistryView&lt;/code&gt; interface to return a Folder List to display in the TreeView.&lt;/p&gt;
&lt;p&gt;Within the &lt;code&gt;RegistryFolderType&lt;/code&gt; the &lt;code&gt;ParameterName&lt;/code&gt; represents the configuration property name which will receive the object name from the list in the TreeView. In this example &amp;quot;Item 1&amp;quot; and &amp;quot;Item 2&amp;quot;.&lt;/p&gt;
&lt;div class="lang-csharp editor-colors"&gt;&lt;div style="color:Black;background-color:White;"&gt;&lt;pre&gt;
&lt;span style="color:Blue;"&gt;public&lt;/span&gt; RegistryConnectionInfo GetRegistryConnectionInfo()
{
    &lt;span style="color:Blue;"&gt;return&lt;/span&gt; &lt;span style="color:Blue;"&gt;new&lt;/span&gt; RegistryConnectionInfo { 
        GroupName = &lt;span style="color:#A31515;"&gt;&amp;quot;Example Provider&amp;quot;&lt;/span&gt;, 
        ConnectionGroupImage = RegistryImageEnum.Folder, 
        ConnectionImage = RegistryImageEnum.Folder 
    };
}

&lt;span style="color:Blue;"&gt;public&lt;/span&gt; RegistryViewContainer GetRegistryViewContainer(&lt;span style="color:Blue;"&gt;string&lt;/span&gt; parent, &lt;span style="color:Blue;"&gt;string&lt;/span&gt; id, &lt;span style="color:Blue;"&gt;object&lt;/span&gt; state)
{
    &lt;span style="color:Blue;"&gt;var&lt;/span&gt; folder = &lt;span style="color:Blue;"&gt;new&lt;/span&gt; RegistryFolderType
    {
        DataType = InstanceHelper.GetTypeNameString(GetType()),
        Image = RegistryImageEnum.Table,
        Preview = &lt;span style="color:Blue;"&gt;true&lt;/span&gt;,
        ParameterName = nameof(Table))
    };

    folder.AddFolderItems(&lt;span style="color:Blue;"&gt;new&lt;/span&gt; &lt;span style="color:Blue;"&gt;string&lt;/span&gt; [] { &lt;span style="color:#A31515;"&gt;&amp;quot;Item 1&amp;quot;&lt;/span&gt;, &lt;span style="color:#A31515;"&gt;&amp;quot;Item 2&amp;quot;&lt;/span&gt; });

    &lt;span style="color:Blue;"&gt;return&lt;/span&gt; &lt;span style="color:Blue;"&gt;new&lt;/span&gt; RegistryViewContainer(folder, &lt;span style="color:Blue;"&gt;null&lt;/span&gt;);
}

&lt;span style="color:Blue;"&gt;public&lt;/span&gt; &lt;span style="color:Blue;"&gt;object&lt;/span&gt; GetRegistryViewConfigurationInterface() =&amp;gt; &lt;span style="color:Blue;"&gt;null&lt;/span&gt;;
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;p&gt;You can add multiple folders and they can be lazy loaded. This &lt;code&gt;GetRegistryViewContainer&lt;/code&gt; method would be called multiple times as the user expands the tree whilst passing the parent folder name.&lt;/p&gt;
&lt;h2 id="writing-back"&gt;Writing Back&lt;/h2&gt;
&lt;p&gt;To create a connector which can write back to your data source you need to create a new class which implements &lt;code&gt;IDataSourceWriter&lt;/code&gt; or ideally derives from &lt;code&gt;DataWriterProviderBase&lt;/code&gt;. You then implement the methods &lt;code&gt;AddItems&lt;/code&gt;, &lt;code&gt;UpdateItems&lt;/code&gt; and &lt;code&gt;DeleteItems&lt;/code&gt;.&lt;/p&gt;
&lt;p&gt;Within your reader you return an instance of this class in the &lt;code&gt;GetWriter&lt;/code&gt; whilst setting the SchemaMap property.&lt;/p&gt;
&lt;div class="lang-csharp editor-colors"&gt;&lt;div style="color:Black;background-color:White;"&gt;&lt;pre&gt;
&lt;span style="color:Blue;"&gt;public&lt;/span&gt; &lt;span style="color:Blue;"&gt;override&lt;/span&gt; IDataSourceWriter GetWriter()
{    
    &lt;span style="color:Blue;"&gt;return&lt;/span&gt; &lt;span style="color:Blue;"&gt;new&lt;/span&gt; ExampleConnectorDatasourceWriter {SchemaMap = SchemaMap};
}
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;p&gt;Within the DataWriter class the &lt;code&gt;Execute&lt;/code&gt; method is called during the write operation and its up to you how you process this. Typically you would call each of the methods &lt;code&gt;AddItems&lt;/code&gt;, &lt;code&gt;UpdateItems&lt;/code&gt; and &lt;code&gt;DeleteItems&lt;/code&gt;.&lt;/p&gt;
&lt;div class="lang-csharp editor-colors"&gt;&lt;div style="color:Black;background-color:White;"&gt;&lt;pre&gt;
&lt;span style="color:Blue;"&gt;public&lt;/span&gt; &lt;span style="color:Blue;"&gt;override&lt;/span&gt; &lt;span style="color:Blue;"&gt;void&lt;/span&gt; Execute(List&amp;lt;DataCompareItem&amp;gt; addItems, List&amp;lt;DataCompareItem&amp;gt; updateItems, List&amp;lt;DataCompareItem&amp;gt; deleteItems, IDataSourceReader reader, IDataSynchronizationStatus status)
{
    &lt;span style="color:Green;"&gt;//Process the Changed Items&lt;/span&gt;
    &lt;span style="color:Blue;"&gt;if&lt;/span&gt; (addItems != &lt;span style="color:Blue;"&gt;null&lt;/span&gt; &amp;amp;&amp;amp; status.ContinueProcessing) AddItems(addItems, status);
    &lt;span style="color:Blue;"&gt;if&lt;/span&gt; (updateItems != &lt;span style="color:Blue;"&gt;null&lt;/span&gt; &amp;amp;&amp;amp; status.ContinueProcessing) UpdateItems(updateItems, status);
    &lt;span style="color:Blue;"&gt;if&lt;/span&gt; (deleteItems != &lt;span style="color:Blue;"&gt;null&lt;/span&gt; &amp;amp;&amp;amp; status.ContinueProcessing) DeleteItems(deleteItems, status);            
}
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;p&gt;An example implementation for &lt;code&gt;AddItems&lt;/code&gt; might look like the code below, where you would fill in the code in the &lt;code&gt;TODO:&lt;/code&gt; section to write the data to the target to create a new record from the data in the &lt;code&gt;targetItem&lt;/code&gt; dictionary object.&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;These examples also handle hooks for Project Automation Item events. If you do not plan to support those then the code can be simplified by removing the Automation Hooks.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;div class="lang-csharp editor-colors"&gt;&lt;div style="color:Black;background-color:White;"&gt;&lt;pre&gt;
&lt;span style="color:Blue;"&gt;public&lt;/span&gt; &lt;span style="color:Blue;"&gt;override&lt;/span&gt; &lt;span style="color:Blue;"&gt;void&lt;/span&gt; AddItems(List&amp;lt;DataCompareItem&amp;gt; items, IDataSynchronizationStatus status)
{
    &lt;span style="color:Blue;"&gt;if&lt;/span&gt; (items != &lt;span style="color:Blue;"&gt;null&lt;/span&gt; &amp;amp;&amp;amp; items.Count &amp;gt; 0)
    {
        &lt;span style="color:Blue;"&gt;int&lt;/span&gt; currentItem = 0;

        &lt;span style="color:Blue;"&gt;foreach&lt;/span&gt; (&lt;span style="color:Blue;"&gt;var&lt;/span&gt; item &lt;span style="color:Blue;"&gt;in&lt;/span&gt; items)
        {
            &lt;span style="color:Blue;"&gt;if&lt;/span&gt; (!status.ContinueProcessing)
                &lt;span style="color:Blue;"&gt;break&lt;/span&gt;;

            &lt;span style="color:Blue;"&gt;try&lt;/span&gt;
            {
                &lt;span style="color:Blue;"&gt;var&lt;/span&gt; itemInvariant = &lt;span style="color:Blue;"&gt;new&lt;/span&gt; DataCompareItemInvariant(item);

                &lt;span style="color:Green;"&gt;//Call the Automation BeforeAddItem (Optional only required if your supporting Automation Item Events)&lt;/span&gt;
                Automation?.BeforeAddItem(&lt;span style="color:Blue;"&gt;this&lt;/span&gt;, itemInvariant, &lt;span style="color:Blue;"&gt;null&lt;/span&gt;);

                &lt;span style="color:Blue;"&gt;if&lt;/span&gt; (itemInvariant.Sync)
                {                    
                    &lt;span style="color:Green;"&gt;//Get the Target Item Data&lt;/span&gt;
                    Dictionary&amp;lt;&lt;span style="color:Blue;"&gt;string&lt;/span&gt;, &lt;span style="color:Blue;"&gt;object&lt;/span&gt;&amp;gt; targetItem = AddItemToDictionary(Mapping, itemInvariant);

                    &lt;span style="color:Green;"&gt;//TODO: Write the code to Add the Item to the Target&lt;/span&gt;

                    &lt;span style="color:Green;"&gt;//Call the Automation AfterAddItem (pass the created item identifier if possible)&lt;/span&gt;
                    Automation?.AfterAddItem(&lt;span style="color:Blue;"&gt;this&lt;/span&gt;, itemInvariant, &lt;span style="color:Blue;"&gt;null&lt;/span&gt;);

                }

                ClearSyncStatus(item); &lt;span style="color:Green;"&gt;//Clear the Sync Flag on Processed Rows&lt;/span&gt;

            }
            &lt;span style="color:Blue;"&gt;catch&lt;/span&gt; (SystemException e)
            {
                HandleError(status, e);
            }
            &lt;span style="color:Blue;"&gt;finally&lt;/span&gt;
            {
                status.Progress(items.Count, ++currentItem); &lt;span style="color:Green;"&gt;//Update the Sync Progress&lt;/span&gt;
            }

        }
    }
}
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;p&gt;For &lt;code&gt;UpdateItems&lt;/code&gt; its slightly different. We use a call to &lt;code&gt;GetTargetIdentifier&amp;lt;T&amp;gt;&lt;/code&gt; to get the identifier value of the row we want to update. This time the &lt;code&gt;targetItem&lt;/code&gt; dictionary object only contains those columns which were changed and you need to fill in the code in the &lt;code&gt;TODO:&lt;/code&gt; section to write the data to the target.&lt;/p&gt;
&lt;div class="lang-csharp editor-colors"&gt;&lt;div style="color:Black;background-color:White;"&gt;&lt;pre&gt;
&lt;span style="color:Blue;"&gt;public&lt;/span&gt; &lt;span style="color:Blue;"&gt;override&lt;/span&gt; &lt;span style="color:Blue;"&gt;void&lt;/span&gt; UpdateItems(List&amp;lt;DataCompareItem&amp;gt; items, IDataSynchronizationStatus status)
{
    &lt;span style="color:Blue;"&gt;if&lt;/span&gt; (items != &lt;span style="color:Blue;"&gt;null&lt;/span&gt; &amp;amp;&amp;amp; items.Count &amp;gt; 0)
    {
        &lt;span style="color:Blue;"&gt;int&lt;/span&gt; currentItem = 0;

        &lt;span style="color:Blue;"&gt;foreach&lt;/span&gt; (&lt;span style="color:Blue;"&gt;var&lt;/span&gt; item &lt;span style="color:Blue;"&gt;in&lt;/span&gt; items)
        {
            &lt;span style="color:Blue;"&gt;if&lt;/span&gt; (!status.ContinueProcessing)
                &lt;span style="color:Blue;"&gt;break&lt;/span&gt;;

            &lt;span style="color:Blue;"&gt;try&lt;/span&gt;
            {
                &lt;span style="color:Blue;"&gt;var&lt;/span&gt; itemInvariant = &lt;span style="color:Blue;"&gt;new&lt;/span&gt; DataCompareItemInvariant(item);

                &lt;span style="color:Green;"&gt;//Example: Get the item ID from the Target Identifier Store &lt;/span&gt;
                &lt;span style="color:Blue;"&gt;var&lt;/span&gt; item_id = itemInvariant.GetTargetIdentifier&amp;lt;&lt;span style="color:Blue;"&gt;int&lt;/span&gt;&amp;gt;();

                &lt;span style="color:Green;"&gt;//Call the Automation BeforeUpdateItem (Optional only required if your supporting Automation Item Events)&lt;/span&gt;
                Automation?.BeforeUpdateItem(&lt;span style="color:Blue;"&gt;this&lt;/span&gt;, itemInvariant, item_id);

                &lt;span style="color:Blue;"&gt;if&lt;/span&gt; (itemInvariant.Sync)
                {
                    &lt;span style="color:Green;"&gt;//Get the Target Item Data&lt;/span&gt;
                    Dictionary&amp;lt;&lt;span style="color:Blue;"&gt;string&lt;/span&gt;, &lt;span style="color:Blue;"&gt;object&lt;/span&gt;&amp;gt; targetItem = UpdateItemToDictionary(Mapping, itemInvariant);

                    &lt;span style="color:Green;"&gt;//TODO: Write the code to Update the Item in the Target using item_id as the Key to the item.&lt;/span&gt;

                    &lt;span style="color:Green;"&gt;//Call the Automation AfterUpdateItem &lt;/span&gt;
                    Automation?.AfterUpdateItem(&lt;span style="color:Blue;"&gt;this&lt;/span&gt;, itemInvariant, item_id);
                }

                ClearSyncStatus(item); &lt;span style="color:Green;"&gt;//Clear the Sync Flag on Processed Rows&lt;/span&gt;
            }
            &lt;span style="color:Blue;"&gt;catch&lt;/span&gt; (SystemException e)
            {
                HandleError(status, e);
            }
            &lt;span style="color:Blue;"&gt;finally&lt;/span&gt;
            {
                status.Progress(items.Count, ++currentItem); &lt;span style="color:Green;"&gt;//Update the Sync Progress&lt;/span&gt;
            }

        }
    }
}
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;p&gt;Finally for &lt;code&gt;DeleteItems&lt;/code&gt;, we can usually just delete the item with the Identifier value.&lt;/p&gt;
&lt;div class="lang-csharp editor-colors"&gt;&lt;div style="color:Black;background-color:White;"&gt;&lt;pre&gt;
&lt;span style="color:Blue;"&gt;public&lt;/span&gt; &lt;span style="color:Blue;"&gt;override&lt;/span&gt; &lt;span style="color:Blue;"&gt;void&lt;/span&gt; DeleteItems(List&amp;lt;DataCompareItem&amp;gt; items, IDataSynchronizationStatus status)
{
    &lt;span style="color:Blue;"&gt;if&lt;/span&gt; (items != &lt;span style="color:Blue;"&gt;null&lt;/span&gt; &amp;amp;&amp;amp; items.Count &amp;gt; 0)
    {
        &lt;span style="color:Blue;"&gt;int&lt;/span&gt; currentItem = 0;

        &lt;span style="color:Blue;"&gt;foreach&lt;/span&gt; (&lt;span style="color:Blue;"&gt;var&lt;/span&gt; item &lt;span style="color:Blue;"&gt;in&lt;/span&gt; items)
        {
            &lt;span style="color:Blue;"&gt;if&lt;/span&gt; (!status.ContinueProcessing)
                &lt;span style="color:Blue;"&gt;break&lt;/span&gt;;

            &lt;span style="color:Blue;"&gt;try&lt;/span&gt;
            {
                &lt;span style="color:Blue;"&gt;var&lt;/span&gt; itemInvariant = &lt;span style="color:Blue;"&gt;new&lt;/span&gt; DataCompareItemInvariant(item);

                &lt;span style="color:Green;"&gt;//Example: Get the item ID from the Target Identifier Store &lt;/span&gt;
                &lt;span style="color:Blue;"&gt;var&lt;/span&gt; item_id = itemInvariant.GetTargetIdentifier&amp;lt;&lt;span style="color:Blue;"&gt;int&lt;/span&gt;&amp;gt;();

                &lt;span style="color:Green;"&gt;//Call the Automation BeforeDeleteItem (Optional only required if your supporting Automation Item Events)&lt;/span&gt;
                Automation?.BeforeDeleteItem(&lt;span style="color:Blue;"&gt;this&lt;/span&gt;, itemInvariant, item_id);

                &lt;span style="color:Blue;"&gt;if&lt;/span&gt; (itemInvariant.Sync)
                {
                    &lt;span style="color:Green;"&gt;//TODO: Write the Code to Delete the Item in the Target using item_id as the Key to the item.&lt;/span&gt;

                    &lt;span style="color:Green;"&gt;//Call the Automation AfterDeleteItem &lt;/span&gt;
                    Automation?.AfterDeleteItem(&lt;span style="color:Blue;"&gt;this&lt;/span&gt;, itemInvariant, item_id);
                }

                ClearSyncStatus(item); &lt;span style="color:Green;"&gt;//Clear the Sync Flag on Processed Rows&lt;/span&gt;
            }
            &lt;span style="color:Blue;"&gt;catch&lt;/span&gt; (SystemException e)
            {
                HandleError(status, e);
            }
            &lt;span style="color:Blue;"&gt;finally&lt;/span&gt;
            {
                status.Progress(items.Count, ++currentItem); &lt;span style="color:Green;"&gt;//Update the Sync Progress&lt;/span&gt;
            }

        }
    }
}
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;h2 id="incremental-data-load"&gt;Incremental Data Load&lt;/h2&gt;
&lt;p&gt;To support Incremental Data Load you need to set &lt;code&gt;SupportsIncrementalReconciliation=true&lt;/code&gt; in the constructor and implement the method &lt;code&gt;GetDataTable(DataTableStore dt, DataTableKeySet keyset)&lt;/code&gt;.&lt;/p&gt;
&lt;p&gt;In Incremental mode we pass a list of keys (keyset) that are the unique key values of the loaded source connection.
In response you need to return a DataTable of the rows with matching keys, each key is expected to be unique and return only 1 result.&lt;/p&gt;
&lt;h2 id="packaging-and-deployment"&gt;Packaging and Deployment&lt;/h2&gt;
&lt;p&gt;To package your connector for deployment you need to compile your connector and compress the required components (typically just your &lt;code&gt;.dll&lt;/code&gt; file) into a zip archive file.
You can then use the &lt;strong&gt;File &amp;gt; Install Data Connector&lt;/strong&gt; feature in Data Sync to install the connector into the DataSync custom connector library.&lt;/p&gt;
&lt;p&gt;Here is an example bat file script which you could use to compile and package into a zip archive.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;set p=ExampleConnector
&amp;quot;C:\Program Files\Microsoft Visual Studio\2022\Enterprise\MSBuild\Current\Bin\msbuild.exe&amp;quot; /t:Build /p:Configuration=Release /p:NoWarn=1591
rmdir ..\dist\ /S /Q
mkdir ..\dist\files\%p%
xcopy ..\src\%p%\bin\Release\net48\*.* ..\dist\files\%p%\*.* /y
cd ..\dist\files\
del .\%p%\Simego.DataSync.Core.dll
tar.exe -acf ..\%p%.zip *.*
cd ..\..\src
&lt;/code&gt;&lt;/pre&gt;
&lt;blockquote&gt;
&lt;p&gt;&lt;strong&gt;NOTE:&lt;/strong&gt; During development you must not have the connector in both places. So if your currently developing your connector make sure to delete it from the Data Sync connector library.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;h2 id="further-information"&gt;Further Information&lt;/h2&gt;
&lt;p&gt;You can checkout some of our open-source connectors in our GitHub repository here &lt;a href="https://github.com/simego-ltd"&gt;github.com/simego-ltd&lt;/a&gt; for more ideas.&lt;/p&gt;
</description>
      <source url="http://www.simego.com/blog">Team Blog</source>
      <pubDate>Tue, 13 Feb 2024 12:55:33 +0000</pubDate>
    </item>
    <item>
      <link>http://www.simego.com/blog/sharepoint-file-datasource-connector</link>
      <author>info@simego.com (Sean Cleaver)</author>
      <title>SharePoint File Data Source Connector</title>
      <description>&lt;p&gt;Data Sync can now connect to a file stored in a SharePoint Document Library and access the data stored within it, without needing to download a copy and reupload it.&lt;/p&gt;
&lt;p&gt;We've had a number of enquiries over the years asking for this functionality and now it is available! So hopefully this fills a gap, and you will all find this connector useful.&lt;/p&gt;
&lt;p&gt;With this connector you can preview, write to and create &lt;strong&gt;CSV&lt;/strong&gt;, &lt;strong&gt;XML&lt;/strong&gt; and &lt;strong&gt;Excel&lt;/strong&gt; files within SharePoint. It will also handle version control, and you can specify the type of check in to be performed i.e. Minor, Major or Overwrite.&lt;/p&gt;
&lt;p&gt;Below we will cover a brief overview of how the connector can be used and a few example use cases. For the full documentation please see our &lt;a href="https://docs.simego.com/data-sync/connectors/sharepoint/cloud-file-datasource" target="_blank"&gt;docs site here&lt;/a&gt;&lt;/p&gt;
&lt;h2 id="connect-to-the-file"&gt;Connect to the File&lt;/h2&gt;
&lt;p&gt;To connect open the data source window, locate the Microsoft SharePoint folder, expand the node and select &lt;strong&gt;SharePoint File Data Source&lt;/strong&gt;.
Then select the connection type, by default this will use the Simego OAuth option but you can also choose to use a custom OAuth connection.&lt;/p&gt;
&lt;p&gt;Enter in the base URL to the SharePoint site. This can be either the root site or a sub-site and should be in the format &lt;code&gt;https://&amp;lt;domain&amp;gt;.sharepoint.com/&amp;lt;site1&amp;gt;/&amp;lt;site2&amp;gt;&lt;/code&gt;.&lt;/p&gt;
&lt;p&gt;Then click &lt;strong&gt;Authorise Connection&lt;/strong&gt; to enable the connection to SharePoint. Once the connection has been authorised you need to enter in the path to the file you want to connect to. This should include the folder paths, the file name and the file extension. For example the path could be &lt;code&gt;/Documents/ContactRecords/Contacts_04-2024.csv&lt;/code&gt;.&lt;/p&gt;
&lt;p&gt;You will need to build this path yourself by navigating through your SharePoint site to the file, making a note of each folder and the order you pass through. The link that can be gathered from the file in SharePoint directly is not user friendly, so you should use a combination of the URL and the filename and extension.&lt;/p&gt;
&lt;p&gt;The final connection should look similar to the image below:&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/sharepoint-file-connection-path.png" alt="SharePoint File Connection" title="SharePoint File Connection" /&gt;&lt;/p&gt;
&lt;p&gt;The connector also supports the connection library. So you can save the connection to the site and just need to specify the path and file type in future connections.&lt;/p&gt;
&lt;p&gt;You can find the documentation pages on this connector on our &lt;a href="https://docs.simego.com/data-sync/connectors/sharepoint/cloud-file-datasource" target="_blank"&gt;Docs site here&lt;/a&gt;.&lt;/p&gt;
&lt;h2 id="use-case-examples"&gt;Use Case Examples&lt;/h2&gt;
&lt;p&gt;Below we discuss a few examples of how this connector could be used in day to day business scenarios to help prompt you with some ideas.
For example creating a backup of a SAAS system, making data available outside of systems that require licenses, feeding data into Power BI models and so on.&lt;/p&gt;
&lt;h2 id="create-new-files-within-sharepoint-for-a-daily-sync"&gt;Create New Files Within SharePoint for a Daily Sync&lt;/h2&gt;
&lt;p&gt;You could use the SharePoint file connector to add a copy of the data edited that day to a folder within SharePoint.
For example you could run a daily sync to capture the contacts added to a contact list in Dynamics today into an XML file.&lt;/p&gt;
&lt;p&gt;To do this you would connect to the Dynamics Contact entity as the source, and a template target XML file that has the column names of the columns you want to capture within SharePoint.&lt;/p&gt;
&lt;p&gt;We can then add a filter to filter for only the contacts that have been modified today using &lt;code&gt;modifiedon &amp;gt;= DATEADD(&amp;quot;day&amp;quot;,-1,TODAY())&lt;/code&gt;.
Next make sure to map the source and target columns in the schema map and ensure a key column has been selected.&lt;/p&gt;
&lt;p&gt;Then using project automation you can override the filename to add today's date to the file name, and specify the path it should be saved to.&lt;/p&gt;
&lt;p&gt;If the folder doesn't exist yet, Data Sync will create this in SharePoint for you. We also need to remember to escape the backslashes in the path with another backslash as it is using C#.&lt;/p&gt;
&lt;div class="lang-csharp editor-colors"&gt;&lt;div style="color:Black;background-color:White;"&gt;&lt;pre&gt;
&lt;span style="color:Blue;"&gt;public&lt;/span&gt; &lt;span style="color:Blue;"&gt;override&lt;/span&gt; &lt;span style="color:Blue;"&gt;void&lt;/span&gt; Start()
{
	DataSourceB.Path = $&lt;span style="color:#A31515;"&gt;&amp;quot;\\Contacts Backup\\UpdatedContactRecords-{DateTime.Today.ToString(&amp;quot;&lt;/span&gt;yyyyMMdd&lt;span style="color:#A31515;"&gt;&amp;quot;)}.xml&amp;quot;&lt;/span&gt;;
}
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;p&gt;The project configuration should then look similar to the below image:&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/sharepoint-file-dynamics-contactxml-project.png" alt="Project Automation" title="Project Automation" /&gt;&lt;/p&gt;
&lt;p&gt;Now when you compare and sync the results, the file will be created in SharePoint and the data uploaded so that you have a full record of the data from that day.&lt;/p&gt;
&lt;h3 id="template-file-doesnt-exist"&gt;Template File Doesn't Exist&lt;/h3&gt;
&lt;p&gt;If the template file you are connecting to doesn't exist yet, you can easily make a template document using the export options in Data Sync.
Add the source columns you want to include in the file to the schema map and then use the Preview A export options from the schema map to export a copy of the data set as an XML/CSV/Excel file.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/datasync-previewoptions.png" alt="Preview Options" title="Preview Options" /&gt;&lt;/p&gt;
&lt;p&gt;You would then need to upload this file into SharePoint and this will act as a template file to connect the target data source window going forward.&lt;/p&gt;
&lt;h2 id="update-the-base-file-for-a-powerbi-model"&gt;Update the base file for a PowerBI model&lt;/h2&gt;
&lt;p&gt;You could use Data Sync and the SharePoint file connector to keep a PowerBI model up to date.
If you set up a regular sync so that the file has the most up to date data, then Power BI can pull data from it when the model refreshed as and when it is needed.&lt;/p&gt;
&lt;p&gt;In short you would use Data Sync to keep the file data up to date and then just refresh the model to get the updates.&lt;/p&gt;
&lt;p&gt;In Data Sync the project would be configured so that your source data feeds into your file within SharePoint on the target. You can set this project to run on a regular basis e.g. at the beginning and end of the day to capture the changes, and the file be set as the data source in PowerBI.&lt;/p&gt;
&lt;p&gt;You then just need to connect your Power BI model to the file and refresh it as needed. We have a quick bit of guidance on connecting the file to Power BI below.&lt;/p&gt;
&lt;h3 id="connecting-to-the-file-in-power-bi"&gt;Connecting to the file in Power BI&lt;/h3&gt;
&lt;p&gt;Sometimes connecting the document in SharePoint to Power BI can throw a few errors. Most of these revolve around getting the right path to the file, so we will briefly cover how to do this.&lt;/p&gt;
&lt;p&gt;To connect to the file in Power BI click onto &lt;strong&gt;Get Data&lt;/strong&gt;. Then select &lt;strong&gt;Web&lt;/strong&gt; from the options list and click Connect.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/sharepoint-file-powerbi-options.png" alt="PowerBI Options" title="PowerBI Options" /&gt;&lt;/p&gt;
&lt;p&gt;You now need to enter in the path to the file in SharePoint.&lt;/p&gt;
&lt;p&gt;The best way to get the right path is to open the file in the desktop app from SharePoint. Then go to File &amp;gt; Info and select &lt;strong&gt;Copy Path&lt;/strong&gt;.
You then need to remove &lt;code&gt;web=1&lt;/code&gt; at the end and the connection should authenticate without any issues.&lt;/p&gt;
&lt;p&gt;This should look something like the following:&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/sharepoint-file-powerbi-path.png" alt="Power BI Path" title="Power BI Path" /&gt;&lt;/p&gt;
&lt;p&gt;Then follow through the wizard to sign in and you should now be able to load or transform the data as needed.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/sharepoint-file-powerbi-connect.png" alt="Power BI Connected" title="Power BI Connected" /&gt;&lt;/p&gt;
&lt;p&gt;Once you have created your model/report in PowerBI you can simply refresh the dataset to get the latest updates whenever you need an updated report.&lt;/p&gt;
&lt;h2 id="create-a-backup-of-your-saas-systems"&gt;Create a Backup of your SAAS Systems&lt;/h2&gt;
&lt;p&gt;Another option is that you could use the SharePoint File Data Source connector to create a backup of your SAAS systems.&lt;/p&gt;
&lt;p&gt;For example you could have an XML file that holds all of your contact records from Salesforce.
You can make this possible by connecting your source to the Salesforce Contact object and the target to the XML file in SharePoint that will hold the records.&lt;/p&gt;
&lt;p&gt;Map the fields you want included in the sync in the schema map and set a key column that link the results (this is usually an ID but could be something different so long as it is unique). Then simply compare the results and sync the changes.
Remember that by default Data Sync disables deletes so any records that have been removed from your Contact object will still exist in the XML file unless you enable deletes.&lt;/p&gt;
&lt;p&gt;We can use project automation to add the date onto the file name and set the path for the backup. You might want use Data Sync to add the file into a specific folder if you are running it multiple times during the day.&lt;/p&gt;
&lt;div class="lang-csharp editor-colors"&gt;&lt;div style="color:Black;background-color:White;"&gt;&lt;pre&gt;
&lt;span style="color:Blue;"&gt;public&lt;/span&gt; &lt;span style="color:Blue;"&gt;override&lt;/span&gt; &lt;span style="color:Blue;"&gt;void&lt;/span&gt; Start()
{
	DataSourceB.Path = $&lt;span style="color:#A31515;"&gt;&amp;quot;\\Salesforce Backup\\ContactObject-{DateTime.Today.ToString(&amp;quot;&lt;/span&gt;yyyyMMdd&lt;span style="color:#A31515;"&gt;&amp;quot;)}.xml&amp;quot;&lt;/span&gt;;
}
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;p&gt;You can make use of Ouvvi or the Run Tool to schedule the project to run on a regular basis. As a backup you might just want to run it at the end of the day, or every hour if the changes are frequent.&lt;/p&gt;
&lt;p&gt;If the file doesn't exist yet you can easily make a template document by adding the fields you want to include in the file to the schema map, and then use the preview export options to export a copy of the data set as an XML file.
You would then need to upload this file into SharePoint and this will act as the template file going forward.&lt;/p&gt;
&lt;h2 id="make-data-available-outside-of-dynamics-for-other-users"&gt;Make Data Available outside of Dynamics for Other Users&lt;/h2&gt;
&lt;p&gt;A slightly different use case is to expose data outside of Dynamics so users can view without a dynamics license - e.g. Exporting a client list into an excel spreadsheet in SharePoint.&lt;/p&gt;
&lt;p&gt;You can connect your source to the client list in Dynamics and the target to the file you want to synchronise the data to.
Map the columns you want to include, run the compare and sync the results.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/sharepoint-file-dynamics-exportmapping.png" alt="Dynamics Export Mapping" title="Dynamics Export Mapping" /&gt;&lt;/p&gt;
&lt;p&gt;Now your employees/ users can view the data without needing to sign into Dynamics. If you also schedule the synchronisation to run every 30 minutes to 1 hour, using either Ouvvi or the Run Tool, then your file will remain up to date for the users. You can set the schedule to meet your needs depending on how frequently the data changes.&lt;/p&gt;
&lt;p&gt;It really is that easy!&lt;/p&gt;
&lt;h2 id="make-employee-to-do-lists-to-split-tasks"&gt;Make Employee To Do Lists to Split Tasks&lt;/h2&gt;
&lt;p&gt;If you have a small team that needs specific tasks (e.g. a call list) splitting up into separate files for each employee, then you could use multiple Data Sync projects to do this.&lt;/p&gt;
&lt;p&gt;To do this you would have one project per employee that creates a spreadsheet they can work from without conflicting with the other users.
You would start by connecting to your source data, which for this example we are saying is a call list that has a user assigned against each account. Then connect the target to a template excel spreadsheet found in SharePoint, that has the columns you want to be included.&lt;/p&gt;
&lt;p&gt;Next you would add a filter on the source to only return records for the first user you are wanting to create the file for, then map the columns between the source and target, and make sure to select a key column to identify each row as unique. This might be an ID column or a composite key of the account name and date (if there is only 1 record per account per day).
Finally you can use Project Automation to write the file to a specific path and add the employee name to the file being created in SharePoint. This would use the same code explained in the previous example where we created new files with today's date only this time it has the date, an employee name, and a specific folder defined in the path. You can see an example shown below:&lt;/p&gt;
&lt;div class="lang-csharp editor-colors"&gt;&lt;div style="color:Black;background-color:White;"&gt;&lt;pre&gt;
&lt;span style="color:Blue;"&gt;public&lt;/span&gt; &lt;span style="color:Blue;"&gt;override&lt;/span&gt; &lt;span style="color:Blue;"&gt;void&lt;/span&gt; Start()
{
	DataSourceB.Path = $&lt;span style="color:#A31515;"&gt;&amp;quot;\\To Do List\\Employee123\\CallList-Employee123-{DateTime.Today.ToString(&amp;quot;&lt;/span&gt;yyyyMMdd&lt;span style="color:#A31515;"&gt;&amp;quot;)}.xlsx&amp;quot;&lt;/span&gt;;
}
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;p&gt;Alternatively for a quick and simple option just export the data to the excel file, include the employee names and let the employee filter the excel document to find their tasks.&lt;/p&gt;
&lt;h2 id="snapshot-sharepoint-list-data"&gt;Snapshot SharePoint List Data&lt;/h2&gt;
&lt;p&gt;An alternative use case is to take a snapshot of some SharePoint list data, so that you can look back and see the data that was contained in that list on a particular day.
This could be for audit purposes, or simply as a backup.&lt;/p&gt;
&lt;p&gt;To do this you would connect your source to the SharePoint list and connect the target to a template file in SharePoint that has the columns you want to include&lt;/p&gt;
&lt;p&gt;If the file doesn't exist yet you can easily make a template document by adding the columns you want to include from the source, to the schema map and then use the preview export options to export a copy of the data set as an XML/CSV/Excel file.
You would then need to upload this file into SharePoint and this will act as a template file to connect the target data source window going forward.&lt;/p&gt;
&lt;p&gt;Make sure the mapping is correct in the schema map and select a key column to identify each row as unique.&lt;/p&gt;
&lt;p&gt;You will then need to use project automation to add the date onto the filename and determine the path the file should be created at.
You can do this by adding the following line of code but make sure the extension matches your file type. The below example is for an excel file so has &lt;code&gt;xlsx&lt;/code&gt; listed.&lt;/p&gt;
&lt;div class="lang-csharp editor-colors"&gt;&lt;div style="color:Black;background-color:White;"&gt;&lt;pre&gt;
&lt;span style="color:Blue;"&gt;public&lt;/span&gt; &lt;span style="color:Blue;"&gt;override&lt;/span&gt; &lt;span style="color:Blue;"&gt;void&lt;/span&gt; Start()
{
	DataSourceB.Path = $&lt;span style="color:#A31515;"&gt;&amp;quot;\\SharePoint SnapShots\\MyListSnapShot-{DateTime.Today.ToString(&amp;quot;&lt;/span&gt;yyyyMMdd&lt;span style="color:#A31515;"&gt;&amp;quot;)}.xlsx&amp;quot;&lt;/span&gt;;
}
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;p&gt;This will now create a new file at the path you defined when you run the synchronisation, and connect to it as the target file.&lt;/p&gt;
&lt;h2 id="export-from-active-directory"&gt;Export from Active Directory&lt;/h2&gt;
&lt;p&gt;LDAP filter for admin or who logged on today for audit purposes.&lt;/p&gt;
&lt;p&gt;A final example could be to export data from Active Directory. This might be a file for auditing the administrators of a group in Active Directory or for who logged in that day.&lt;/p&gt;
&lt;p&gt;This Data Sync project would be connected to Active Directory as the source and export the data to a file within SharePoint to act as an audit file for that day.
You could then add in date to the file name using project automation to create new file.&lt;/p&gt;
&lt;div class="lang-csharp editor-colors"&gt;&lt;div style="color:Black;background-color:White;"&gt;&lt;pre&gt;
&lt;span style="color:Blue;"&gt;public&lt;/span&gt; &lt;span style="color:Blue;"&gt;override&lt;/span&gt; &lt;span style="color:Blue;"&gt;void&lt;/span&gt; Start()
{
	DataSourceB.Path = $&lt;span style="color:#A31515;"&gt;&amp;quot;\\Active Directory Audit Data\\UsersLoggedIn-EOD-{DateTime.Today.ToString(&amp;quot;&lt;/span&gt;yyyyMMdd&lt;span style="color:#A31515;"&gt;&amp;quot;)}.csv&amp;quot;&lt;/span&gt;;
}
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;p&gt;To get the logged in users you could simply apply a filter to your source data (Users in AD) to only return those with a value of Todays date for the DS-LastLogon attribute.&lt;/p&gt;
&lt;p&gt;This filter could look like this: &lt;code&gt;DSLastLogon &amp;gt;= DATEADD(&amp;quot;day&amp;quot;,-1,TODAY())&lt;/code&gt;&lt;/p&gt;
&lt;p&gt;Then map the columns between the source data and target file in SharePoint, run the compare and Sync the results.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/sharepoint-file-ad-auditproject.png" alt="AD Audit Export Project" title="AD Audit Export Project" /&gt;&lt;/p&gt;
&lt;p&gt;To get the admin members into a file you could connect to the users list and use an LDAP filter to only return the only return Administrators. Then follow the same steps as above and you will get the file created in SharePoint.&lt;/p&gt;
&lt;p&gt;We would then recommend scheduling the project to run so that it runs every day at the end of the day to give you a full audit history. You can do this with either Ouvvi or the Run Tool.&lt;/p&gt;
&lt;p&gt;If you have any questions about how to make a specific scenario work for you, send us an email and we will be happy to help get you started.&lt;/p&gt;
</description>
      <source url="http://www.simego.com/blog">Team Blog</source>
      <pubDate>Wed, 10 Apr 2024 12:55:33 +0000</pubDate>
    </item>
    <item>
      <link>http://www.simego.com/blog/simego-updates</link>
      <author>info@simego.com (Sean Cleaver)</author>
      <title>Simego Updates</title>
      <description>


&lt;section class="section-tiny main-color"&gt;
    &lt;div class="container"&gt;
        &lt;div class="row"&gt;
            &lt;div class="col-md-12"&gt;
                &lt;h2 class="section-title"&gt;
                    Microsoft.Data.SqlClient
                &lt;/h2&gt;
                &lt;div class="section-sub-title"&gt;Version 6.0.3396&lt;/div&gt;
                &lt;p&gt;
                    Since Microsoft have deprecated the &lt;code&gt;System.Data.SqlClient&lt;/code&gt; library we have updated Data Sync to use the newer &lt;code&gt;Microsoft.Data.SqlClient&lt;/code&gt; library.
                    This enables more authentication options especially with SQL Azure which can be configured via the 'Additional Connection Properties' property pane.
                &lt;/p&gt;                
                &lt;p&gt;
                    The change should be seamless however since these connections are now Encrypted by default if you have an older connection string you may need to update it to &lt;code&gt;Trust the Server Certificate&lt;/code&gt;.
                &lt;/p&gt;
            &lt;/div&gt;
        &lt;/div&gt;
    &lt;/div&gt;
&lt;/section&gt;

&lt;section class="section-tiny alternate-color"&gt;
    &lt;div class="container"&gt;
        &lt;div class="row"&gt;
            &lt;div class="col-md-12"&gt;
                &lt;h2 class="section-title"&gt;
                    Set Sync Mode in Project Automation
                &lt;/h2&gt;
                &lt;div class="section-sub-title"&gt;Version 6.0.3388&lt;/div&gt;
                &lt;p&gt;
                    We have made it possible to adjust the Sync Mode at runtime within the &lt;code&gt;Start()&lt;/code&gt; or &lt;code&gt;GetDataSchema()&lt;/code&gt; methods of Project Automation.
                &lt;/p&gt;
                &lt;pre&gt;SyncMode = SyncModeEnum.SyncAtoBIncremental;&lt;/pre&gt;                
                &lt;p&gt;This allows for custom synchronisation scenarios where you can adapt the sync based on some condition. See &lt;a href="/blog/dynamics-to-sql-export"&gt;Dynamics to SQL Export&lt;/a&gt; for an example.&lt;/p&gt;
            &lt;/div&gt;
        &lt;/div&gt;
    &lt;/div&gt;
&lt;/section&gt;


&lt;section class="section-tiny main-color"&gt;
    &lt;div class="container"&gt;
        &lt;div class="row"&gt;
            &lt;div class="col-md-12"&gt;
                &lt;h2 class="section-title"&gt;
                    OAuth Certificate Authentication
                &lt;/h2&gt;
                &lt;div class="section-sub-title"&gt;Version 6.0.3372&lt;/div&gt;
                &lt;p&gt;
                    We have extended our OAuth2 support to include Client Certificate Support in place of a Client Secret.
                &lt;/p&gt;
                &lt;p&gt;
                    Certificates are loaded from the Windows Certificate Store and therefore the process will need access to the Private Key. If you use the LocalMachine certificate store then ensure that the Ouvvi Service user has permission to read the private key. Additionally if you want to manage the connection from Ouvvi ensure that the Ouvvi AppPool user also has permission to the private key.

                &lt;/p&gt;
                &lt;p&gt;
                    In this version &lt;strong&gt;6.0.3372&lt;/strong&gt; we have support for using certificates with &lt;code&gt;authorization_code&lt;/code&gt; and &lt;code&gt;client_credentials&lt;/code&gt; flows with the following connectors.
                    &lt;ul&gt;
                        &lt;li&gt;SharePoint Online&lt;/li&gt;
                        &lt;li&gt;SharePoint FileStore (used to access data inside Excel/CSV files in a document library)&lt;/li&gt;
                        &lt;li&gt;Dynamics 365&lt;/li&gt;
                        &lt;li&gt;SQL Azure&lt;/li&gt;
                        &lt;li&gt;JSON API Tool&lt;/li&gt;
                    &lt;/ul&gt;
                &lt;/p&gt;

                &lt;p&gt;
                    You can specify either the thumbprint or subject name as the certificate setting in the connection.

                &lt;/p&gt;
                &lt;p&gt;
                    You can also specify the full path i.e. &lt;strong&gt;LocalMachine\My\DataSync-SharePoint&lt;/strong&gt; or just &lt;strong&gt;DataSync-SharePoint&lt;/strong&gt; and we will look for the certificate in the &lt;strong&gt;My&lt;/strong&gt; store location in both the LocalMachine and CurrentUser stores.

                &lt;/p&gt;
                &lt;p&gt;
                    Since we now support certificates its possible to connect with SharePoint using &lt;code&gt;client_credentials&lt;/code&gt; flow and use application level permission rather than a delegated user. This prevents your integration projects being tied to a user account.
                &lt;/p&gt;                               
            &lt;/div&gt;
        &lt;/div&gt;
    &lt;/div&gt;
&lt;/section&gt;




&lt;section class="section-tiny alternate-color"&gt;
    &lt;div class="container"&gt;
        &lt;div class="row"&gt;
            &lt;div class="col-md-12"&gt;
                &lt;h2 class="section-title"&gt;
                    Ouvvi Time Trigger - Window
                &lt;/h2&gt;
                &lt;div class="section-sub-title"&gt;Version 6.0.3370&lt;/div&gt;
                &lt;p&gt;
                    We had a customer request to prevent Time Triggers to running after a certain time. By default if a trigger time is missed due to the service not running because if an IT issue or similar,
                    The trigger runs when the service is restarted. Generally this is what you want, However for this customer they did not want to run resource heavy overnight tasks during the day if this occurred.
                &lt;/p&gt;
                &lt;p&gt;
                    The solution to this is a new &lt;code&gt;EndTime&lt;/code&gt; setting on the Time Trigger which defaults to '23:59:59'. Now if the End Time period has passed the trigger does not evaluate and therefore start the attached projects. So you can now configure a Time Trigger to run between say &lt;strong&gt;03:00:00&lt;/strong&gt; and &lt;strong&gt;05:00:00&lt;/strong&gt;  to prevent the trigger running after 5AM.
                &lt;/p&gt;
            &lt;/div&gt;
        &lt;/div&gt;
    &lt;/div&gt;
&lt;/section&gt;

&lt;section class="section-tiny main-color t-bordered"&gt;
    &lt;div class="container"&gt;
        &lt;div class="row"&gt;
            &lt;div class="col-md-12"&gt;
                &lt;div class="section-sub-title"&gt;
                    If you have any feedback or would like us to consider a new feature please reach out to us at support@simego.com.
                &lt;/div&gt;                
            &lt;/div&gt;
        &lt;/div&gt;
    &lt;/div&gt;
&lt;/section&gt;</description>
      <source url="http://www.simego.com/blog">Team Blog</source>
      <pubDate>Tue, 24 Sep 2024 12:55:33 +0000</pubDate>
    </item>
    <item>
      <link>http://www.simego.com/blog/dynamics-to-sql-export</link>
      <author>info@simego.com (Sean Cleaver)</author>
      <title>Dynamics to SQL Data Export</title>
      <description>&lt;p&gt;In this guide we show how you can use Data Synchronisation Studio to build a Dynamics/Dataverse to SQL Server Data Export solution.
Whilst only creating a single Data Sync project and using Project Automation to enable automatic creation of SQL Tables from the Dynamics schema.&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;You could also use this approach with other Datasources like Salesforce or SharePoint.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;h2 id="overview"&gt;Overview&lt;/h2&gt;
&lt;p&gt;We will build a single Data Sync project which will automatically update itself based on the requested entity.
If the schema of the entity changes we will drop the existing table and re-create it.&lt;/p&gt;
&lt;p&gt;The steps required for this to work are as follows.&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Connect to Entity named in Project Property.&lt;/li&gt;
&lt;li&gt;Discover Dynamics Entity Schema.&lt;/li&gt;
&lt;li&gt;Create matching SQL Table in SQL Database from the Dynamics Schema.&lt;/li&gt;
&lt;li&gt;Check if the schema has changed and re-create the table if necessary.&lt;/li&gt;
&lt;li&gt;Setup Source and Target in the Data Sync project and update Schema Map to match.&lt;/li&gt;
&lt;/ul&gt;
&lt;h3 id="command-line"&gt;Command Line&lt;/h3&gt;
&lt;p&gt;Once this project is configured you can call the sync for different entities right from the command line like this.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&amp;quot;%DATASYNCINSTALLPATH60%\Simego.DataSync.Run.exe&amp;quot; -e project.dsprj -p:entity=account
&amp;quot;%DATASYNCINSTALLPATH60%\Simego.DataSync.Run.exe&amp;quot; -e project.dsprj -p:entity=contact
&lt;/code&gt;&lt;/pre&gt;
&lt;h2 id="setup-project"&gt;Setup Project&lt;/h2&gt;
&lt;p&gt;First we need a SQL Table in our target database used to track which entities have been created and a hash value of the schema columns.&lt;/p&gt;
&lt;p&gt;Use the script below to create your table for tracking the created entity tables.&lt;/p&gt;
&lt;div class="lang-SQL editor-colors"&gt;&lt;div style="color:Black;background-color:White;"&gt;&lt;pre&gt;
&lt;span style="color:Blue;"&gt;CREATE&lt;/span&gt; &lt;span style="color:Blue;"&gt;TABLE&lt;/span&gt; [dbo].[_dsTableMetadata] (
	[ID] &lt;span style="color:Blue;"&gt;int&lt;/span&gt; &lt;span style="color:Blue;"&gt;IDENTITY&lt;/span&gt;(1, 1) &lt;span style="color:Blue;"&gt;NOT&lt;/span&gt; &lt;span style="color:Blue;"&gt;NULL&lt;/span&gt;,
	[Name] &lt;span style="color:Blue;"&gt;nvarchar&lt;/span&gt;(255) &lt;span style="color:Blue;"&gt;NOT&lt;/span&gt; &lt;span style="color:Blue;"&gt;NULL&lt;/span&gt;,
	[Hash] &lt;span style="color:Blue;"&gt;nvarchar&lt;/span&gt;(100) &lt;span style="color:Blue;"&gt;NOT&lt;/span&gt; &lt;span style="color:Blue;"&gt;NULL&lt;/span&gt;,
	[Script] &lt;span style="color:Blue;"&gt;nvarchar&lt;/span&gt;(&lt;span style="color:Magenta;"&gt;MAX&lt;/span&gt;) &lt;span style="color:Blue;"&gt;NULL&lt;/span&gt;,
	[Created] &lt;span style="color:Blue;"&gt;datetime&lt;/span&gt; &lt;span style="color:Blue;"&gt;DEFAULT&lt;/span&gt;(&lt;span style="color:Blue;"&gt;getutcdate&lt;/span&gt;()) &lt;span style="color:Blue;"&gt;NOT&lt;/span&gt; &lt;span style="color:Blue;"&gt;NULL&lt;/span&gt;,
	[Updated] &lt;span style="color:Blue;"&gt;datetime&lt;/span&gt; &lt;span style="color:Blue;"&gt;DEFAULT&lt;/span&gt;(&lt;span style="color:Blue;"&gt;getutcdate&lt;/span&gt;()) &lt;span style="color:Blue;"&gt;NOT&lt;/span&gt; &lt;span style="color:Blue;"&gt;NULL&lt;/span&gt;
)
GO

&lt;span style="color:Blue;"&gt;ALTER&lt;/span&gt; &lt;span style="color:Blue;"&gt;TABLE&lt;/span&gt; [dbo].[_dsTableMetadata] &lt;span style="color:Blue;"&gt;ADD&lt;/span&gt; &lt;span style="color:Blue;"&gt;CONSTRAINT&lt;/span&gt; [PK__dsTableMetadata_BCAF3B7C] &lt;span style="color:Blue;"&gt;PRIMARY&lt;/span&gt; &lt;span style="color:Blue;"&gt;KEY&lt;/span&gt; &lt;span style="color:Blue;"&gt;CLUSTERED&lt;/span&gt; ([ID] &lt;span style="color:Blue;"&gt;ASC&lt;/span&gt;) 
GO
&lt;span style="color:Blue;"&gt;ALTER&lt;/span&gt; &lt;span style="color:Blue;"&gt;TABLE&lt;/span&gt; [dbo].[_dsTableMetadata] &lt;span style="color:Blue;"&gt;ADD&lt;/span&gt; &lt;span style="color:Blue;"&gt;CONSTRAINT&lt;/span&gt; [IX__dsTableMetadata_FDE2506A] &lt;span style="color:Blue;"&gt;UNIQUE&lt;/span&gt; &lt;span style="color:Blue;"&gt;NONCLUSTERED&lt;/span&gt; ([Name] &lt;span style="color:Blue;"&gt;ASC&lt;/span&gt;) 
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;p&gt;Next we need a DataSync Project configured with connection from the Connection Library for Dynamics and SQL.
At this point it doesn't really matter about the Schema Map and if the project works its about configuring the source and target systems.&lt;/p&gt;
&lt;p&gt;Start with a new Project and connect the source to the Dynamics 'account' entity from the Connection Library. Then connect the Target to a SQL Table from the Connection Library.&lt;/p&gt;
&lt;p&gt;Under &lt;code&gt;File-&amp;gt;Properties-&amp;gt;Properties&lt;/code&gt; add a new Project Property named 'entity' with a value 'account'.&lt;/p&gt;
&lt;h2 id="project-automation-code"&gt;Project Automation Code&lt;/h2&gt;
&lt;p&gt;This is the code which dynamically creates a SQL Table matching the source Data Schema and sets up the project and schema map to match.&lt;/p&gt;
&lt;p&gt;These are the steps we need the code to complete.&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Setup the source and target to point to the Entity value stored in the Project Property &lt;code&gt;entity&lt;/code&gt;.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;Then when the Schema Map is requested in the &lt;code&gt;GetDataSchema&lt;/code&gt; override function.&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Get the source Schema.&lt;/li&gt;
&lt;li&gt;Check if the SQL Table already exists in the SQL Database or whether to re-create the Table.&lt;/li&gt;
&lt;li&gt;Converts the source schema into a SQL Table script.&lt;/li&gt;
&lt;li&gt;Create the SQL Table on the target SQL Server.&lt;/li&gt;
&lt;li&gt;Return the updated Schema Map.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;Enable Project Automation on your project and replace the code with this version below.&lt;/p&gt;
&lt;div class="lang-csharp editor-colors"&gt;&lt;div style="color:Black;background-color:White;"&gt;&lt;pre&gt;
&lt;span style="color:Blue;"&gt;using&lt;/span&gt; System;
&lt;span style="color:Blue;"&gt;using&lt;/span&gt; System.Collections.Generic;
&lt;span style="color:Blue;"&gt;using&lt;/span&gt; System.Data;
&lt;span style="color:Blue;"&gt;using&lt;/span&gt; System.Globalization;
&lt;span style="color:Blue;"&gt;using&lt;/span&gt; System.Linq;
&lt;span style="color:Blue;"&gt;using&lt;/span&gt; System.Text;
&lt;span style="color:Blue;"&gt;using&lt;/span&gt; Simego.DataSync;
&lt;span style="color:Blue;"&gt;using&lt;/span&gt; Simego.DataSync.Engine;

&lt;span style="color:Blue;"&gt;class&lt;/span&gt; ProjectAutomationOverride : Simego.DataSync.Automation.ProjectAutomationShim &lt;span style="color:Green;"&gt;//Do Not Change This Line&lt;/span&gt;
{    	
    &lt;span style="color:Blue;"&gt;public&lt;/span&gt; &lt;span style="color:Blue;"&gt;override&lt;/span&gt; &lt;span style="color:Blue;"&gt;void&lt;/span&gt; Start()
    {
        &lt;span style="color:Green;"&gt;// Set the Entity on DataSource A&lt;/span&gt;
        DataSourceA.Entity = Properties[&lt;span style="color:#A31515;"&gt;&amp;quot;entity&amp;quot;&lt;/span&gt;];		
        &lt;span style="color:Green;"&gt;// Set the Entity in DataSource B&lt;/span&gt;
        DataSourceB.SourceTable = $&lt;span style="color:#A31515;"&gt;&amp;quot;[dbo].[{DataSourceA.Entity}]&amp;quot;&lt;/span&gt;;
        &lt;span style="color:Green;"&gt;// AutoMap the Schema		&lt;/span&gt;
        AutoSchemaMap = &lt;span style="color:Blue;"&gt;true&lt;/span&gt;;		
    }
    
    &lt;span style="color:Blue;"&gt;public&lt;/span&gt; &lt;span style="color:Blue;"&gt;override&lt;/span&gt; DataSchema GetDataSchema(DataSchema schema)
    {
        &lt;span style="color:Blue;"&gt;var&lt;/span&gt; schemaA = DataSourceA.GetDefaultDataSchema();
        
        &lt;span style="color:Green;"&gt;// Get the Key columns for the PK.&lt;/span&gt;
        &lt;span style="color:Blue;"&gt;var&lt;/span&gt; keyColumns = &lt;span style="color:Blue;"&gt;string&lt;/span&gt;.Join(&lt;span style="color:#A31515;"&gt;&amp;quot;, &amp;quot;&lt;/span&gt;, schemaA.GetUniqueColumns().Select(p =&amp;gt; $&lt;span style="color:#A31515;"&gt;&amp;quot;[{p.ColumnName}]&amp;quot;&lt;/span&gt;));
        
        &lt;span style="color:Green;"&gt;// Get the column list&lt;/span&gt;
        &lt;span style="color:Blue;"&gt;var&lt;/span&gt; columns = &lt;span style="color:Blue;"&gt;string&lt;/span&gt;.Join(&lt;span style="color:#A31515;"&gt;&amp;quot;,\r\n&amp;quot;&lt;/span&gt;, schemaA.Map.Where(p =&amp;gt; isValidColumn(p)).Select(column =&amp;gt; $&lt;span style="color:#A31515;"&gt;&amp;quot;\t[{column.ColumnName}] {getSqlColumnType(column)} {(column.AllowNull ? &amp;quot;&lt;/span&gt;NULL&lt;span style="color:#A31515;"&gt;&amp;quot; : &amp;quot;&lt;/span&gt;NOT NULL&lt;span style="color:#A31515;"&gt;&amp;quot;)}&amp;quot;&lt;/span&gt;));
        
        &lt;span style="color:Green;"&gt;// Generate a Hash of the columns to detect if any have changed.&lt;/span&gt;
        &lt;span style="color:Blue;"&gt;var&lt;/span&gt; columnHash = getHash(columns);
                
        &lt;span style="color:Green;"&gt;// Check if the entity Table already exists in the DB. By getting the existing Hash from our _dsTableMetadata table.&lt;/span&gt;
        &lt;span style="color:Blue;"&gt;var&lt;/span&gt; existingHash = DataSourceB.ExecuteScalar($&lt;span style="color:#A31515;"&gt;&amp;quot;SELECT Hash FROM _dsTableMetadata WHERE Name = &amp;#39;{DataSourceB.SourceTable}&amp;#39;&amp;quot;&lt;/span&gt;) &lt;span style="color:Blue;"&gt;as&lt;/span&gt; &lt;span style="color:Blue;"&gt;string&lt;/span&gt;;
        &lt;span style="color:Blue;"&gt;if&lt;/span&gt; (existingHash == &lt;span style="color:Blue;"&gt;null&lt;/span&gt;)
        {									
            &lt;span style="color:Green;"&gt;// Create Table Script&lt;/span&gt;
            &lt;span style="color:Blue;"&gt;var&lt;/span&gt; tableScript = getTableScript(keyColumns, columns);
            
            &lt;span style="color:Green;"&gt;// Create the Target Table&lt;/span&gt;
            DataSourceB.ExecuteNonQuery(tableScript);	
            
            &lt;span style="color:Green;"&gt;// Update the _dsTableMetadata Table&lt;/span&gt;
            DataSourceB.ExecuteNonQuery(&lt;span style="color:#A31515;"&gt;&amp;quot;INSERT INTO [dbo].[_dsTableMetadata] (Name, Hash, Script) VALUES (@p0, @p1, @p2)&amp;quot;&lt;/span&gt;, DataSourceB.SourceTable, columnHash, tableScript);
            
            &lt;span style="color:Green;"&gt;// Write to Log&lt;/span&gt;
            Trace.WriteLine($&lt;span style="color:#A31515;"&gt;&amp;quot;Created Table &amp;#39;{DataSourceB.SourceTable}&amp;#39;&amp;quot;&lt;/span&gt;);			
        } 
        &lt;span style="color:Blue;"&gt;else&lt;/span&gt; &lt;span style="color:Blue;"&gt;if&lt;/span&gt;(existingHash != columnHash)
        {			
            &lt;span style="color:Green;"&gt;// Create Table Script&lt;/span&gt;
            &lt;span style="color:Blue;"&gt;var&lt;/span&gt; tableScript = getTableScript(keyColumns, columns);
            
            &lt;span style="color:Green;"&gt;// Update the _dsTableMetadata Table&lt;/span&gt;
            DataSourceB.ExecuteNonQuery(&lt;span style="color:#A31515;"&gt;&amp;quot;UPDATE [dbo].[_dsTableMetadata] SET Hash=@p0, Script=@p1, Updated=getutcdate() WHERE Name=@p2&amp;quot;&lt;/span&gt;, columnHash, tableScript, DataSourceB.SourceTable);
            
            &lt;span style="color:Green;"&gt;// Drop the existing Table&lt;/span&gt;
            DataSourceB.ExecuteNonQuery($&lt;span style="color:#A31515;"&gt;&amp;quot;DROP TABLE {DataSourceB.SourceTable}&amp;quot;&lt;/span&gt;);	
            
            &lt;span style="color:Green;"&gt;// Create the Target Table&lt;/span&gt;
            DataSourceB.ExecuteNonQuery(tableScript);	
                                    
            &lt;span style="color:Green;"&gt;// Write to Log&lt;/span&gt;
            Trace.WriteLine($&lt;span style="color:#A31515;"&gt;&amp;quot;Updated Table &amp;#39;{DataSourceB.SourceTable}&amp;#39;&amp;quot;&lt;/span&gt;);			
        }
        
        &lt;span style="color:Green;"&gt;// Get the Target Schema&lt;/span&gt;
        &lt;span style="color:Blue;"&gt;var&lt;/span&gt; schemaB = DataSourceB.GetDefaultDataSchema();
        
        &lt;span style="color:Green;"&gt;// Return an Auto-Map&lt;/span&gt;
        &lt;span style="color:Blue;"&gt;return&lt;/span&gt; AutoSchemaMap ? schemaA.ToAutoMap(schemaB) : schema;
    }
    
    &lt;span style="color:Blue;"&gt;string&lt;/span&gt; getTableScript(&lt;span style="color:Blue;"&gt;string&lt;/span&gt; keyColumns, &lt;span style="color:Blue;"&gt;string&lt;/span&gt; columns)
    {
        &lt;span style="color:Blue;"&gt;return&lt;/span&gt; &lt;span style="color:Blue;"&gt;string&lt;/span&gt;.Concat(
                $&lt;span style="color:#A31515;"&gt;&amp;quot;CREATE TABLE {DataSourceB.SourceTable} (\r\n&amp;quot;&lt;/span&gt;,
                &lt;span style="color:Green;"&gt;// Append the Columns&lt;/span&gt;
                columns,
                &lt;span style="color:#A31515;"&gt;&amp;quot;)\r\n&amp;quot;&lt;/span&gt;,
                &lt;span style="color:Green;"&gt;// Add the Primary Key&lt;/span&gt;
                $&lt;span style="color:#A31515;"&gt;&amp;quot;ALTER TABLE {DataSourceB.SourceTable} ADD CONSTRAINT [PK_dbo_{DataSourceA.Entity}] PRIMARY KEY CLUSTERED ({keyColumns})\r\n&amp;quot;&lt;/span&gt;);
            
    }
    
    &lt;span style="color:Blue;"&gt;bool&lt;/span&gt; isValidColumn(DataSchemaItem column)
    {
        &lt;span style="color:Green;"&gt;// Use to Filter out invalid columns.&lt;/span&gt;
        &lt;span style="color:Blue;"&gt;return&lt;/span&gt; &lt;span style="color:Blue;"&gt;true&lt;/span&gt;;
    }
        
    &lt;span style="color:Blue;"&gt;string&lt;/span&gt; getSqlColumnType(DataSchemaItem column)
    {			
        &lt;span style="color:Blue;"&gt;switch&lt;/span&gt;(column.DataType.FullName)
        {
            &lt;span style="color:Blue;"&gt;case&lt;/span&gt; &lt;span style="color:#A31515;"&gt;&amp;quot;System.Guid&amp;quot;&lt;/span&gt;: 
            {
                &lt;span style="color:Blue;"&gt;return&lt;/span&gt; &lt;span style="color:#A31515;"&gt;&amp;quot;uniqueidentifier&amp;quot;&lt;/span&gt;;
            }
            &lt;span style="color:Blue;"&gt;case&lt;/span&gt; &lt;span style="color:#A31515;"&gt;&amp;quot;System.Int64&amp;quot;&lt;/span&gt;: 
            {
                &lt;span style="color:Blue;"&gt;return&lt;/span&gt; &lt;span style="color:#A31515;"&gt;&amp;quot;bigint&amp;quot;&lt;/span&gt;;
            }
            &lt;span style="color:Blue;"&gt;case&lt;/span&gt; &lt;span style="color:#A31515;"&gt;&amp;quot;System.Int16&amp;quot;&lt;/span&gt;: 
            &lt;span style="color:Blue;"&gt;case&lt;/span&gt; &lt;span style="color:#A31515;"&gt;&amp;quot;System.Int32&amp;quot;&lt;/span&gt;: 
            {
                &lt;span style="color:Blue;"&gt;return&lt;/span&gt; &lt;span style="color:#A31515;"&gt;&amp;quot;int&amp;quot;&lt;/span&gt;;
            }
            &lt;span style="color:Blue;"&gt;case&lt;/span&gt; &lt;span style="color:#A31515;"&gt;&amp;quot;System.Single&amp;quot;&lt;/span&gt;: 
            &lt;span style="color:Blue;"&gt;case&lt;/span&gt; &lt;span style="color:#A31515;"&gt;&amp;quot;System.Double&amp;quot;&lt;/span&gt;: 
            {
                &lt;span style="color:Blue;"&gt;return&lt;/span&gt; &lt;span style="color:#A31515;"&gt;&amp;quot;float&amp;quot;&lt;/span&gt;;
            }
            &lt;span style="color:Blue;"&gt;case&lt;/span&gt; &lt;span style="color:#A31515;"&gt;&amp;quot;System.Decimal&amp;quot;&lt;/span&gt;: 
            {
                &lt;span style="color:Blue;"&gt;return&lt;/span&gt; &lt;span style="color:#A31515;"&gt;&amp;quot;decimal(19,4)&amp;quot;&lt;/span&gt;;
            }
            &lt;span style="color:Blue;"&gt;case&lt;/span&gt; &lt;span style="color:#A31515;"&gt;&amp;quot;Simego.DataSync.Date&amp;quot;&lt;/span&gt;: 
            &lt;span style="color:Blue;"&gt;case&lt;/span&gt; &lt;span style="color:#A31515;"&gt;&amp;quot;System.DateTime&amp;quot;&lt;/span&gt;: 
            {
                &lt;span style="color:Blue;"&gt;return&lt;/span&gt; &lt;span style="color:#A31515;"&gt;&amp;quot;datetime&amp;quot;&lt;/span&gt;;
            }
            &lt;span style="color:Blue;"&gt;case&lt;/span&gt; &lt;span style="color:#A31515;"&gt;&amp;quot;System.Boolean&amp;quot;&lt;/span&gt;: 
            {
                &lt;span style="color:Blue;"&gt;return&lt;/span&gt; &lt;span style="color:#A31515;"&gt;&amp;quot;bit&amp;quot;&lt;/span&gt;;
            }
            &lt;span style="color:Blue;"&gt;case&lt;/span&gt; &lt;span style="color:#A31515;"&gt;&amp;quot;System.String&amp;quot;&lt;/span&gt;: 
            {
                &lt;span style="color:Blue;"&gt;if&lt;/span&gt;(column.Length &amp;gt; 0 &amp;amp;&amp;amp; column.Length &amp;lt; 4000)
                {
                    &lt;span style="color:Blue;"&gt;return&lt;/span&gt; $&lt;span style="color:#A31515;"&gt;&amp;quot;nvarchar({column.Length})&amp;quot;&lt;/span&gt;;
                }	
                &lt;span style="color:Blue;"&gt;if&lt;/span&gt;(column.ColumnName.EndsWith(&lt;span style="color:#A31515;"&gt;&amp;quot;codename&amp;quot;&lt;/span&gt;))
                {
                    &lt;span style="color:Blue;"&gt;return&lt;/span&gt; &lt;span style="color:#A31515;"&gt;&amp;quot;nvarchar(100)&amp;quot;&lt;/span&gt;;	 
                }
                &lt;span style="color:Blue;"&gt;break&lt;/span&gt;;
            }
        }
            
        &lt;span style="color:Green;"&gt;// Default Column value&lt;/span&gt;
        &lt;span style="color:Blue;"&gt;return&lt;/span&gt; &lt;span style="color:#A31515;"&gt;&amp;quot;nvarchar(4000)&amp;quot;&lt;/span&gt;;
    }
    
    &lt;span style="color:Blue;"&gt;static&lt;/span&gt; &lt;span style="color:Blue;"&gt;string&lt;/span&gt; getHash(&lt;span style="color:Blue;"&gt;string&lt;/span&gt; input)
    {
        &lt;span style="color:Blue;"&gt;using&lt;/span&gt; (&lt;span style="color:Blue;"&gt;var&lt;/span&gt; sha1 = System.Security.Cryptography.SHA1.Create())
        {
            &lt;span style="color:Green;"&gt;// Convert hash bytes to hex string&lt;/span&gt;
            &lt;span style="color:Blue;"&gt;return&lt;/span&gt; &lt;span style="color:Blue;"&gt;string&lt;/span&gt;.Concat(sha1.ComputeHash(Encoding.UTF8.GetBytes(input)).Select(b =&amp;gt; b.ToString(&lt;span style="color:#A31515;"&gt;&amp;quot;x2&amp;quot;&lt;/span&gt;)));            
        }
    }
}
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;blockquote&gt;
&lt;p&gt;You can adjust this code to work best for you its just a guide on the process you may want look at how the SQL Columns are defined and potentially implement some column filtering via the &lt;code&gt;isValidColumn&lt;/code&gt; function.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;h2 id="test-project"&gt;Test Project&lt;/h2&gt;
&lt;p&gt;You can now test this project by running in the designer you should see an 'account' table is created and there is a result in the 'Compare Results' window to write to the SQL Table.&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;Note: The Designer doesn't always update the UI when running dynamically like this only when re-opening the Data Sync project file.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;h3 id="command-line-1"&gt;Command Line&lt;/h3&gt;
&lt;p&gt;You can now run this on the command line to process each entity you want to sync.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&amp;quot;%DATASYNCINSTALLPATH60%\Simego.DataSync.Run.exe&amp;quot; -e project.dsprj -p:entity=account
&amp;quot;%DATASYNCINSTALLPATH60%\Simego.DataSync.Run.exe&amp;quot; -e project.dsprj -p:entity=contact
&lt;/code&gt;&lt;/pre&gt;
&lt;h3 id="ouvvi"&gt;Ouvvi&lt;/h3&gt;
&lt;p&gt;You can use the &lt;strong&gt;Run Tool Project&lt;/strong&gt; step in Ouvvi to run these and pass the entity name in the App Settings.&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;By running these via the RunTool step means they are run in a new process which has a performance hit on loading the Dynamics Schema. We are building a new Step Handler for Ouvvi to allow you to run these steps In-Process from a single project file and pass the project property configuration.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/ouvvi-dynamics-sql-export.png" alt="Using Ouvvi to Run the Sync" /&gt;&lt;/p&gt;
&lt;p&gt;The Ouvvi Step should be a RunTool Project Step where we can pass the Entity name via the App Settings. By using the value &lt;code&gt;{{StepName}}&lt;/code&gt; we can inject the name of the Ouvvi Project Step as the Entity name.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/ouvvi-dynamics-sql-export-step-config.png" alt="Configure RunTool Step" /&gt;&lt;/p&gt;
&lt;h2 id="improving-performance-incremental-sync"&gt;Improving Performance - Incremental Sync&lt;/h2&gt;
&lt;blockquote&gt;
&lt;p&gt;Requires an update to Data Sync Version 6.0.3388&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;We can improve the performance of the synchronisation process by using an incremental sync where possible and using a new Ouvvi Step handler to ensure the steps run In-Process with the Ouvvi Service.&lt;/p&gt;
&lt;p&gt;To implement &lt;code&gt;Incremental Sync&lt;/code&gt; we need to change the Data Sync Mode to return those records which have a greater version number since the last sync.
Dynamics entities have a column &lt;code&gt;versionnumber&lt;/code&gt; which we can use with a Fetch XML Filter to return only those changed records.&lt;/p&gt;
&lt;p&gt;We need to store the last version number in our metadata SQL Table and then use this to filter the source records on the next sync. Use the SQL below to add a new column to the metadata table to store the version number.&lt;/p&gt;
&lt;div class="lang-SQL editor-colors"&gt;&lt;div style="color:Black;background-color:White;"&gt;&lt;pre&gt;
&lt;span style="color:Blue;"&gt;ALTER&lt;/span&gt; &lt;span style="color:Blue;"&gt;TABLE&lt;/span&gt; [dbo].[_dsTableMetadata] &lt;span style="color:Blue;"&gt;ADD&lt;/span&gt; [VersionNumber] &lt;span style="color:Blue;"&gt;bigint&lt;/span&gt; &lt;span style="color:Blue;"&gt;NOT&lt;/span&gt; &lt;span style="color:Blue;"&gt;NULL&lt;/span&gt; &lt;span style="color:Blue;"&gt;DEFAULT&lt;/span&gt;(0)
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;p&gt;By changing our code to check for this column we can switch the sync mode in Project Automation and apply this filter at runtime.
The code below includes the changes to switch to incremental mode and update the Fetch XML Filter at runtime to only return those changed records.&lt;/p&gt;
&lt;div class="lang-csharp editor-colors"&gt;&lt;div style="color:Black;background-color:White;"&gt;&lt;pre&gt;
&lt;span style="color:Blue;"&gt;using&lt;/span&gt; System;
&lt;span style="color:Blue;"&gt;using&lt;/span&gt; System.Collections.Generic;
&lt;span style="color:Blue;"&gt;using&lt;/span&gt; System.Data;
&lt;span style="color:Blue;"&gt;using&lt;/span&gt; System.Globalization;
&lt;span style="color:Blue;"&gt;using&lt;/span&gt; System.Linq;
&lt;span style="color:Blue;"&gt;using&lt;/span&gt; System.Text;
&lt;span style="color:Blue;"&gt;using&lt;/span&gt; Simego.DataSync;
&lt;span style="color:Blue;"&gt;using&lt;/span&gt; Simego.DataSync.Engine;

&lt;span style="color:Blue;"&gt;class&lt;/span&gt; ProjectAutomationOverride : Simego.DataSync.Automation.ProjectAutomationShim &lt;span style="color:Green;"&gt;//Do Not Change This Line&lt;/span&gt;
{    	
	&lt;span style="color:Blue;"&gt;public&lt;/span&gt; &lt;span style="color:Blue;"&gt;override&lt;/span&gt; &lt;span style="color:Blue;"&gt;void&lt;/span&gt; Start()
	{
		&lt;span style="color:Green;"&gt;// Set the Entity on DataSource A&lt;/span&gt;
		DataSourceA.Entity = Properties[&lt;span style="color:#A31515;"&gt;&amp;quot;entity&amp;quot;&lt;/span&gt;];		
		&lt;span style="color:Green;"&gt;// Set the Entity in DataSource B&lt;/span&gt;
		DataSourceB.SourceTable = $&lt;span style="color:#A31515;"&gt;&amp;quot;[dbo].[{DataSourceA.Entity}]&amp;quot;&lt;/span&gt;;		
		&lt;span style="color:Green;"&gt;// AutoMap the Schema		&lt;/span&gt;
		AutoSchemaMap = &lt;span style="color:Blue;"&gt;true&lt;/span&gt;;					
	}
		
	&lt;span style="color:Blue;"&gt;public&lt;/span&gt; &lt;span style="color:Blue;"&gt;override&lt;/span&gt; DataSchema GetDataSchema(DataSchema schema)
	{
		&lt;span style="color:Green;"&gt;// Set the Sync Mode to Normal&lt;/span&gt;
		SyncMode = SyncModeEnum.SyncAtoB;
		&lt;span style="color:Green;"&gt;// Reset the Fetch Expression&lt;/span&gt;
		DataSourceA.FetchXmlFilterExpression = &lt;span style="color:Blue;"&gt;null&lt;/span&gt;;
				
		&lt;span style="color:Green;"&gt;// Load the Source Schema&lt;/span&gt;
		&lt;span style="color:Blue;"&gt;var&lt;/span&gt; schemaA = DataSourceA.GetDefaultDataSchema();
	    
		&lt;span style="color:Green;"&gt;// Get the Key columns for the PK.&lt;/span&gt;
		&lt;span style="color:Blue;"&gt;var&lt;/span&gt; keyColumns = &lt;span style="color:Blue;"&gt;string&lt;/span&gt;.Join(&lt;span style="color:#A31515;"&gt;&amp;quot;, &amp;quot;&lt;/span&gt;, schemaA.GetUniqueColumns().Select(p =&amp;gt; $&lt;span style="color:#A31515;"&gt;&amp;quot;[{p.ColumnName}]&amp;quot;&lt;/span&gt;));
		
		&lt;span style="color:Green;"&gt;// Get the column list&lt;/span&gt;
		&lt;span style="color:Blue;"&gt;var&lt;/span&gt; columns = &lt;span style="color:Blue;"&gt;string&lt;/span&gt;.Join(&lt;span style="color:#A31515;"&gt;&amp;quot;,\r\n&amp;quot;&lt;/span&gt;, schemaA.Map.Where(p =&amp;gt; isValidColumn(p)).Select(column =&amp;gt; $&lt;span style="color:#A31515;"&gt;&amp;quot;\t[{column.ColumnName}] {getSqlColumnType(column)} {(column.AllowNull ? &amp;quot;&lt;/span&gt;NULL&lt;span style="color:#A31515;"&gt;&amp;quot; : &amp;quot;&lt;/span&gt;NOT NULL&lt;span style="color:#A31515;"&gt;&amp;quot;)}&amp;quot;&lt;/span&gt;));
		
		&lt;span style="color:Green;"&gt;// Generate a Hash of the columns to detect if any have changed.&lt;/span&gt;
		&lt;span style="color:Blue;"&gt;var&lt;/span&gt; columnHash = getHash(columns);
				
		&lt;span style="color:Green;"&gt;// Check if the entity Table already exists in the DB. By getting the existing Hash from our _dsTableMetadata table.&lt;/span&gt;
		&lt;span style="color:Blue;"&gt;var&lt;/span&gt; existingHash = DataSourceB.ExecuteScalar($&lt;span style="color:#A31515;"&gt;&amp;quot;SELECT Hash FROM _dsTableMetadata WHERE Name = &amp;#39;{DataSourceB.SourceTable}&amp;#39;&amp;quot;&lt;/span&gt;) &lt;span style="color:Blue;"&gt;as&lt;/span&gt; &lt;span style="color:Blue;"&gt;string&lt;/span&gt;;
		&lt;span style="color:Blue;"&gt;if&lt;/span&gt; (existingHash == &lt;span style="color:Blue;"&gt;null&lt;/span&gt;)
		{									
			&lt;span style="color:Green;"&gt;// Create Table Script&lt;/span&gt;
			&lt;span style="color:Blue;"&gt;var&lt;/span&gt; tableScript = getTableScript(keyColumns, columns);
			
			&lt;span style="color:Green;"&gt;// Create the Target Table&lt;/span&gt;
			DataSourceB.ExecuteNonQuery(tableScript);	
			
			&lt;span style="color:Green;"&gt;// Update the _dsTableMetadata Table&lt;/span&gt;
			DataSourceB.ExecuteNonQuery(&lt;span style="color:#A31515;"&gt;&amp;quot;INSERT INTO [dbo].[_dsTableMetadata] (Name, Hash, Script) VALUES (@p0, @p1, @p2)&amp;quot;&lt;/span&gt;, DataSourceB.SourceTable, columnHash, tableScript);
			
			&lt;span style="color:Green;"&gt;// Write to Log&lt;/span&gt;
			Trace.WriteLine($&lt;span style="color:#A31515;"&gt;&amp;quot;Created Table &amp;#39;{DataSourceB.SourceTable}&amp;#39;&amp;quot;&lt;/span&gt;);			
		} 
		&lt;span style="color:Blue;"&gt;else&lt;/span&gt; &lt;span style="color:Blue;"&gt;if&lt;/span&gt;(existingHash != columnHash)
		{			
			&lt;span style="color:Green;"&gt;// Create Table Script&lt;/span&gt;
			&lt;span style="color:Blue;"&gt;var&lt;/span&gt; tableScript = getTableScript(keyColumns, columns);
			
			&lt;span style="color:Green;"&gt;// Update the _dsTableMetadata Table&lt;/span&gt;
			DataSourceB.ExecuteNonQuery(&lt;span style="color:#A31515;"&gt;&amp;quot;UPDATE [dbo].[_dsTableMetadata] SET Hash=@p0, Script=@p1, Updated=getutcdate() WHERE Name=@p2&amp;quot;&lt;/span&gt;, columnHash, tableScript, DataSourceB.SourceTable);
			
			&lt;span style="color:Green;"&gt;// Drop the existing Table&lt;/span&gt;
			DataSourceB.ExecuteNonQuery($&lt;span style="color:#A31515;"&gt;&amp;quot;DROP TABLE {DataSourceB.SourceTable}&amp;quot;&lt;/span&gt;);	
			
			&lt;span style="color:Green;"&gt;// Create the Target Table&lt;/span&gt;
			DataSourceB.ExecuteNonQuery(tableScript);	
									
			&lt;span style="color:Green;"&gt;// Write to Log&lt;/span&gt;
			Trace.WriteLine($&lt;span style="color:#A31515;"&gt;&amp;quot;Updated Table &amp;#39;{DataSourceB.SourceTable}&amp;#39;&amp;quot;&lt;/span&gt;);					
		}
		&lt;span style="color:Blue;"&gt;else&lt;/span&gt;
		{	
			&lt;span style="color:Green;"&gt;// If this Entity has a &amp;#39;versionnumber&amp;#39; column set the project to an incremental sync.&lt;/span&gt;
			&lt;span style="color:Blue;"&gt;if&lt;/span&gt;(schemaA.Map.Any(p =&amp;gt; p.ColumnName == &lt;span style="color:#A31515;"&gt;&amp;quot;versionnumber&amp;quot;&lt;/span&gt;))
			{				
				&lt;span style="color:Blue;"&gt;var&lt;/span&gt; previousVersionNumber = DataSchemaTypeConverter.ConvertTo&amp;lt;Int64?&amp;gt;(DataSourceB.ExecuteScalar($&lt;span style="color:#A31515;"&gt;&amp;quot;SELECT VersionNumber FROM _dsTableMetadata WHERE Name=&amp;#39;{DataSourceB.SourceTable}&amp;#39;&amp;quot;&lt;/span&gt;)) ?? 0;
		
				&lt;span style="color:Blue;"&gt;if&lt;/span&gt;(previousVersionNumber &amp;gt; 0)
				{				
					&lt;span style="color:Green;"&gt;// Set the Sync Mode to Incremental&lt;/span&gt;
					SyncMode = SyncModeEnum.SyncAtoBIncremental;
					
					&lt;span style="color:Green;"&gt;// Filter based on checkpoint.&lt;/span&gt;
					&lt;span style="color:Blue;"&gt;var&lt;/span&gt; fetchXml = $&lt;span style="color:#A31515;"&gt;&amp;quot;&amp;lt;order attribute=&amp;#39;versionnumber&amp;#39; descending=&amp;#39;false&amp;#39;/&amp;gt;&amp;lt;filter type=&amp;#39;and&amp;#39;&amp;gt;&amp;lt;condition attribute=&amp;#39;versionnumber&amp;#39; operator=&amp;#39;gt&amp;#39; value=&amp;#39;{previousVersionNumber}&amp;#39;/&amp;gt;&amp;lt;/filter&amp;gt;&amp;quot;&lt;/span&gt;;

					&lt;span style="color:Green;"&gt;// Set the DataSource Filter&lt;/span&gt;
					DataSourceA.FetchXmlFilterExpression = fetchXml;
				}
			}
		}
		
		&lt;span style="color:Green;"&gt;// Get the Target Schema&lt;/span&gt;
		&lt;span style="color:Blue;"&gt;var&lt;/span&gt; schemaB = DataSourceB.GetDefaultDataSchema();
		
		&lt;span style="color:Green;"&gt;// Return an Auto-Map&lt;/span&gt;
		&lt;span style="color:Blue;"&gt;return&lt;/span&gt; AutoSchemaMap ? schemaA.ToAutoMap(schemaB) : schema;
	}
	
	
	&lt;span style="color:Blue;"&gt;public&lt;/span&gt; &lt;span style="color:Blue;"&gt;override&lt;/span&gt; &lt;span style="color:Blue;"&gt;void&lt;/span&gt; End(ProjectAutomationResult result)
	{
		&lt;span style="color:Blue;"&gt;if&lt;/span&gt;(result.Success)
		{
			&lt;span style="color:Blue;"&gt;if&lt;/span&gt;(result.CompareResult.Schema.Map.Any(p =&amp;gt; p.ColumnName == &lt;span style="color:#A31515;"&gt;&amp;quot;versionnumber&amp;quot;&lt;/span&gt;))
			{
				&lt;span style="color:Green;"&gt;// Update the VersionNumber in the Metadata Table&lt;/span&gt;
				DataSourceB.ExecuteNonQuery($&lt;span style="color:#A31515;"&gt;&amp;quot;UPDATE _dsTableMetadata SET VersionNumber = (SELECT COALESCE(MAX(versionnumber), 0) FROM {DataSourceB.SourceTable}) WHERE Name=&amp;#39;{DataSourceB.SourceTable}&amp;#39;&amp;quot;&lt;/span&gt;);
			}
		}	
	}
	
	&lt;span style="color:Blue;"&gt;string&lt;/span&gt; getTableScript(&lt;span style="color:Blue;"&gt;string&lt;/span&gt; keyColumns, &lt;span style="color:Blue;"&gt;string&lt;/span&gt; columns)
	{
		&lt;span style="color:Blue;"&gt;return&lt;/span&gt; &lt;span style="color:Blue;"&gt;string&lt;/span&gt;.Concat(
				$&lt;span style="color:#A31515;"&gt;&amp;quot;CREATE TABLE {DataSourceB.SourceTable} (\r\n&amp;quot;&lt;/span&gt;,
				&lt;span style="color:Green;"&gt;// Append the Columns&lt;/span&gt;
				columns,
				&lt;span style="color:#A31515;"&gt;&amp;quot;)\r\n&amp;quot;&lt;/span&gt;,
				&lt;span style="color:Green;"&gt;// Add the Primary Key&lt;/span&gt;
				$&lt;span style="color:#A31515;"&gt;&amp;quot;ALTER TABLE {DataSourceB.SourceTable} ADD CONSTRAINT [PK_dbo_{DataSourceA.Entity}] PRIMARY KEY CLUSTERED ({keyColumns})\r\n&amp;quot;&lt;/span&gt;);
			
	}
	
	&lt;span style="color:Blue;"&gt;bool&lt;/span&gt; isValidColumn(DataSchemaItem column)
	{
		&lt;span style="color:Green;"&gt;// Use to Filter out invalid columns.&lt;/span&gt;
		&lt;span style="color:Blue;"&gt;return&lt;/span&gt; &lt;span style="color:Blue;"&gt;true&lt;/span&gt;;
	}
		
	&lt;span style="color:Blue;"&gt;string&lt;/span&gt; getSqlColumnType(DataSchemaItem column)
	{			
		&lt;span style="color:Blue;"&gt;switch&lt;/span&gt;(column.DataType.FullName)
		{
			&lt;span style="color:Blue;"&gt;case&lt;/span&gt; &lt;span style="color:#A31515;"&gt;&amp;quot;System.Guid&amp;quot;&lt;/span&gt;: 
			{
				&lt;span style="color:Blue;"&gt;return&lt;/span&gt; &lt;span style="color:#A31515;"&gt;&amp;quot;uniqueidentifier&amp;quot;&lt;/span&gt;;
			}
			&lt;span style="color:Blue;"&gt;case&lt;/span&gt; &lt;span style="color:#A31515;"&gt;&amp;quot;System.Int64&amp;quot;&lt;/span&gt;: 
			{
				&lt;span style="color:Blue;"&gt;return&lt;/span&gt; &lt;span style="color:#A31515;"&gt;&amp;quot;bigint&amp;quot;&lt;/span&gt;;
			}
			&lt;span style="color:Blue;"&gt;case&lt;/span&gt; &lt;span style="color:#A31515;"&gt;&amp;quot;System.Int16&amp;quot;&lt;/span&gt;: 
			&lt;span style="color:Blue;"&gt;case&lt;/span&gt; &lt;span style="color:#A31515;"&gt;&amp;quot;System.Int32&amp;quot;&lt;/span&gt;: 
			{
				&lt;span style="color:Blue;"&gt;return&lt;/span&gt; &lt;span style="color:#A31515;"&gt;&amp;quot;int&amp;quot;&lt;/span&gt;;
			}
			&lt;span style="color:Blue;"&gt;case&lt;/span&gt; &lt;span style="color:#A31515;"&gt;&amp;quot;System.Single&amp;quot;&lt;/span&gt;: 
			&lt;span style="color:Blue;"&gt;case&lt;/span&gt; &lt;span style="color:#A31515;"&gt;&amp;quot;System.Double&amp;quot;&lt;/span&gt;: 
			{
				&lt;span style="color:Blue;"&gt;return&lt;/span&gt; &lt;span style="color:#A31515;"&gt;&amp;quot;float&amp;quot;&lt;/span&gt;;
			}
			&lt;span style="color:Blue;"&gt;case&lt;/span&gt; &lt;span style="color:#A31515;"&gt;&amp;quot;System.Decimal&amp;quot;&lt;/span&gt;: 
			{
				&lt;span style="color:Blue;"&gt;return&lt;/span&gt; &lt;span style="color:#A31515;"&gt;&amp;quot;decimal(19,4)&amp;quot;&lt;/span&gt;;
			}
			&lt;span style="color:Blue;"&gt;case&lt;/span&gt; &lt;span style="color:#A31515;"&gt;&amp;quot;Simego.DataSync.Date&amp;quot;&lt;/span&gt;: 
			&lt;span style="color:Blue;"&gt;case&lt;/span&gt; &lt;span style="color:#A31515;"&gt;&amp;quot;System.DateTime&amp;quot;&lt;/span&gt;: 
			{
				&lt;span style="color:Blue;"&gt;return&lt;/span&gt; &lt;span style="color:#A31515;"&gt;&amp;quot;datetime&amp;quot;&lt;/span&gt;;
			}
			&lt;span style="color:Blue;"&gt;case&lt;/span&gt; &lt;span style="color:#A31515;"&gt;&amp;quot;System.Boolean&amp;quot;&lt;/span&gt;: 
			{
				&lt;span style="color:Blue;"&gt;return&lt;/span&gt; &lt;span style="color:#A31515;"&gt;&amp;quot;bit&amp;quot;&lt;/span&gt;;
			}
			&lt;span style="color:Blue;"&gt;case&lt;/span&gt; &lt;span style="color:#A31515;"&gt;&amp;quot;System.String&amp;quot;&lt;/span&gt;: 
			{
				&lt;span style="color:Blue;"&gt;if&lt;/span&gt;(column.Length &amp;gt; 0 &amp;amp;&amp;amp; column.Length &amp;lt; 4000)
				{
					&lt;span style="color:Blue;"&gt;return&lt;/span&gt; $&lt;span style="color:#A31515;"&gt;&amp;quot;nvarchar({column.Length})&amp;quot;&lt;/span&gt;;
				}	
				&lt;span style="color:Blue;"&gt;if&lt;/span&gt;(column.ColumnName.EndsWith(&lt;span style="color:#A31515;"&gt;&amp;quot;codename&amp;quot;&lt;/span&gt;))
				{
					&lt;span style="color:Blue;"&gt;return&lt;/span&gt; &lt;span style="color:#A31515;"&gt;&amp;quot;nvarchar(100)&amp;quot;&lt;/span&gt;;	 
				}
				&lt;span style="color:Blue;"&gt;break&lt;/span&gt;;
			}
		}
			
		&lt;span style="color:Green;"&gt;// Default Column value&lt;/span&gt;
		&lt;span style="color:Blue;"&gt;return&lt;/span&gt; &lt;span style="color:#A31515;"&gt;&amp;quot;nvarchar(4000)&amp;quot;&lt;/span&gt;;
	}
	
	&lt;span style="color:Blue;"&gt;static&lt;/span&gt; &lt;span style="color:Blue;"&gt;string&lt;/span&gt; getHash(&lt;span style="color:Blue;"&gt;string&lt;/span&gt; input)
    {
        &lt;span style="color:Blue;"&gt;using&lt;/span&gt; (&lt;span style="color:Blue;"&gt;var&lt;/span&gt; sha1 = System.Security.Cryptography.SHA1.Create())
        {
			&lt;span style="color:Green;"&gt;// Convert hash bytes to hex string&lt;/span&gt;
            &lt;span style="color:Blue;"&gt;return&lt;/span&gt; &lt;span style="color:Blue;"&gt;string&lt;/span&gt;.Concat(sha1.ComputeHash(Encoding.UTF8.GetBytes(input)).Select(b =&amp;gt; b.ToString(&lt;span style="color:#A31515;"&gt;&amp;quot;x2&amp;quot;&lt;/span&gt;)));            
        }
    }
}
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;h3 id="ouvvi-1"&gt;Ouvvi&lt;/h3&gt;
&lt;p&gt;We can now use a new Ouvvi Step handler to run a Data Sync project from a file and pass the name of the entity as a project property just like the Run Tool Step.
Use the &lt;code&gt;Data Sync Project File&lt;/code&gt; step type with a User Setting pointing to the actual file path so it can be easily changed.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/ouvvi-dynamics-sql-export-config-new.png" alt="Ouvvi Data Sync Project File Step" /&gt;&lt;/p&gt;
&lt;p&gt;To add additional entities to the export you only need to use the &lt;code&gt;Copy Step&lt;/code&gt; function and name it the same as the Dynamics entity.&lt;/p&gt;
&lt;p&gt;Now you should see that the sync can run through much quicker as those with no changes will be processed quickly.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/ouvvi-dynamics-sql-export-new.png" alt="Ouvvi Dynamics to SQL Export" /&gt;&lt;/p&gt;
</description>
      <source url="http://www.simego.com/blog">Team Blog</source>
      <pubDate>Wed, 30 Oct 2024 12:39:33 +0000</pubDate>
    </item>
    <item>
      <link>http://www.simego.com/blog/json-api-connector</link>
      <author>info@simego.com (Sean Cleaver)</author>
      <title>Data Sync Connector for JSON Web APIs</title>
      <description>&lt;p&gt;We have come up with a new way to easily connect Data Sync V6 to virtually any JSON based Web API.&lt;/p&gt;
&lt;h2 id="features"&gt;Features&lt;/h2&gt;
&lt;ul&gt;
&lt;li&gt;Read/Write Data Access (New! Write access as of version 6.0.3300)&lt;/li&gt;
&lt;li&gt;Define Multiple Datasources&lt;/li&gt;
&lt;li&gt;Automatic API Definition Discovery&lt;/li&gt;
&lt;li&gt;Parametrized configuration variables&lt;/li&gt;
&lt;li&gt;Authentication
&lt;ul&gt;
&lt;li&gt;OAuth2 (authorization_code and client_credentials flows)&lt;/li&gt;
&lt;li&gt;Basic Authentication&lt;/li&gt;
&lt;li&gt;Http Headers&lt;/li&gt;
&lt;li&gt;Authorization Header (Bearer Authentication)&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;For Each Loops&lt;/li&gt;
&lt;li&gt;Paging Requests&lt;/li&gt;
&lt;li&gt;HTTP Fetch (GET, POST, PUT, PATCH, DELETE)&lt;/li&gt;
&lt;li&gt;Read Json File&lt;/li&gt;
&lt;li&gt;Lookups&lt;/li&gt;
&lt;li&gt;Connection Registry&lt;/li&gt;
&lt;li&gt;XML based API definition&lt;/li&gt;
&lt;li&gt;API GUI Designer&lt;/li&gt;
&lt;/ul&gt;
&lt;h2 id="json-api-designer"&gt;JSON API Designer&lt;/h2&gt;
&lt;p&gt;The JSON API Designer &lt;code&gt;Tools-&amp;gt;JSON API Tool&lt;/code&gt; in Data Sync makes it easy to create the XML API definition for the API.
The Designer also allows for quick API configuration by way of an Automatic configuration from a URL, We will load the JSON from the URL and attempt to define a Schema and Fetch operation automatically.
From the Designer you can quickly connect your API to the source or target of your project.&lt;/p&gt;
&lt;p&gt;In the screenshot below we have loaded an API definition for multiple datasources which also use a Dynamic Schema and OAuth2 based authentication.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/json-api-designer-screenshot.png" alt="JSON API Designer Screenshot" /&gt;&lt;/p&gt;
&lt;h3 id="auto-generate-api-specification"&gt;Auto Generate API Specification&lt;/h3&gt;
&lt;p&gt;You can automatically generate the API specification from a URL using the &lt;code&gt;Add Datasource from URL&lt;/code&gt; function. This will attempt to download the json response and build the datasource specification from the response.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://images.simego.com/blog/json-api-designer-add-datasource.png" alt="JSON API Create Datasource from URL" /&gt;&lt;/p&gt;
&lt;h2 id="simple-api-definition"&gt;Simple API Definition&lt;/h2&gt;
&lt;p&gt;The connector is based on a simple XML Schema which defines the operations required for the connector to function.
Data Sync connectors require 2 main functions &lt;strong&gt;GetDataSchema&lt;/strong&gt; which must return the datasource schema to define the schema map.
&lt;strong&gt;GetDataTable&lt;/strong&gt; which returns the data as a Data Table.&lt;/p&gt;
&lt;p&gt;The API XML definition below describes a simple API and defines a Static Schema Map, URL to fetch the response and a Data Transform to fill the Data Table from the response.&lt;/p&gt;
&lt;div class="lang-xml editor-colors"&gt;&lt;div style="color:Black;background-color:White;"&gt;&lt;pre&gt;
&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Connector&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;ODataV4 Sample&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;description&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;Connect to an OData V4 Feed&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;version&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;1.0&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
  &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Datasources&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
    &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Datasource&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;People&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
      &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Actions&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
        &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Action&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;GetDataSchema&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
          &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;StaticSchemaMap&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
            &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Column&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;UserName&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;type&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;System.String&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;unique&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;true&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;allownull&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;false&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
            &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Column&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;FirstName&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;type&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;System.String&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;length&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;255&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
            &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Column&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;LastName&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;type&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;System.String&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
            &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Column&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;Emails&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;type&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;JArray&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
          &lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;StaticSchemaMap&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
        &lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Action&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
        &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Action&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;GetDataTable&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
          &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Fetch&lt;/span&gt; &lt;span style="color:Red;"&gt;url&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;https://services.odata.org/TripPinRESTierService/People&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
            &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;DataTableTransform&lt;/span&gt; &lt;span style="color:Red;"&gt;path&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;value&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
          &lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Fetch&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
        &lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Action&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
      &lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Actions&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
    &lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Datasource&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
  &lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Datasources&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
&lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Connector&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;

&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;h2 id="data-paging"&gt;Data Paging&lt;/h2&gt;
&lt;p&gt;Many JSON APIs implement some form of Data paging where they limit the number of records returned in the response.
These can be implemented in many random ways and we have built a &lt;code&gt;PagingRequest&lt;/code&gt; function to handle the most common.&lt;/p&gt;
&lt;h3 id="page-counter"&gt;Page Counter&lt;/h3&gt;
&lt;p&gt;The most simple is the Page counter where we keep incrementing a page number until the response returns an empty response.&lt;/p&gt;
&lt;div class="lang-xml editor-colors"&gt;&lt;div style="color:Black;background-color:White;"&gt;&lt;pre&gt;
&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;PagingRequest&lt;/span&gt; &lt;span style="color:Red;"&gt;path&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;data&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;start&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;1&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
  &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Fetch&lt;/span&gt; &lt;span style="color:Red;"&gt;url&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;{URL}/app/list/{Datasource.Name}?limit={PageSize}&amp;amp;amp;page={PagingRequest.Page}&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
    &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;DataTableTransform&lt;/span&gt; &lt;span style="color:Red;"&gt;path&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;data&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
  &lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Fetch&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
&lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;PagingRequest&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;h3 id="next-page-token"&gt;Next Page Token&lt;/h3&gt;
&lt;p&gt;The next page token method is based on extracting the value for the next page and passing it in the next request until the next page token is empty.&lt;/p&gt;
&lt;div class="lang-xml editor-colors"&gt;&lt;div style="color:Black;background-color:White;"&gt;&lt;pre&gt;
&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;PagingRequest&lt;/span&gt; &lt;span style="color:Red;"&gt;path&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;data&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;start&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;1&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;next-path&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;nextpage&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
  &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Fetch&lt;/span&gt; &lt;span style="color:Red;"&gt;url&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;{URL}/app/list/{Datasource.Name}?limit={PageSize}&amp;amp;amp;page={PagingRequest.Next}&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
    &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;DataTableTransform&lt;/span&gt; &lt;span style="color:Red;"&gt;path&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;data&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
  &lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Fetch&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
&lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;PagingRequest&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;p&gt;Alternatively if the Next Page token returns a URL to the next page of results then you can use it like this.
Where you pass the first page in the &lt;code&gt;next&lt;/code&gt; token which sets up the initial request and the next page URL is returned from &lt;code&gt;next-path&lt;/code&gt; token.
The paging process will complete when the value of the &lt;code&gt;next-page&lt;/code&gt; token returns null or empty string.&lt;/p&gt;
&lt;div class="lang-xml editor-colors"&gt;&lt;div style="color:Black;background-color:White;"&gt;&lt;pre&gt;
&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;PagingRequest&lt;/span&gt; &lt;span style="color:Red;"&gt;path&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;data&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;start&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;1&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;next&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;{URL}/app/list/{Datasource.Name}?limit={PageSize}&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;next-path&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;next&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
  &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Fetch&lt;/span&gt; &lt;span style="color:Red;"&gt;url&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;{PagingRequest.Next}&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
    &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;DataTableTransform&lt;/span&gt; &lt;span style="color:Red;"&gt;path&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;data&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
  &lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Fetch&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
&lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;PagingRequest&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;h3 id="next-page-token-with-continuation-parameter"&gt;Next Page Token with Continuation Parameter&lt;/h3&gt;
&lt;p&gt;&lt;em&gt;Requires DataSync Version: 6.0.3532+&lt;/em&gt;&lt;/p&gt;
&lt;p&gt;This is a variation on the Next Page token for when the last page returns the current page token instead of null to signal the end.
Instead it uses another value to tell you whether to continue or not.&lt;/p&gt;
&lt;p&gt;Here we use &lt;code&gt;while-path&lt;/code&gt; and &lt;code&gt;while-path-value&lt;/code&gt; which are used with a string equality check to decide if the loop should continue.
In the example below the loop continues all the time &lt;strong&gt;meta.has_more&lt;/strong&gt; equals &lt;strong&gt;'True'&lt;/strong&gt;.&lt;/p&gt;
&lt;div class="lang-xml editor-colors"&gt;&lt;div style="color:Black;background-color:White;"&gt;&lt;pre&gt;
&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;PagingRequest&lt;/span&gt; &lt;span style="color:Red;"&gt;path&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;data&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;start&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;1&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;next&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;{URL}/app/list/{Datasource.Name}?limit={PageSize}&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;next-path&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;next&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;while-path&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;meta.has_more&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;while-path-value&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;True&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
  &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Fetch&lt;/span&gt; &lt;span style="color:Red;"&gt;url&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;{PagingRequest.Next}&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
    &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;DataTableTransform&lt;/span&gt; &lt;span style="color:Red;"&gt;path&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;data&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
  &lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Fetch&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
&lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;PagingRequest&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;h3 id="skip-take"&gt;Skip &amp;amp; Take&lt;/h3&gt;
&lt;p&gt;If your API is based on a Skip and Take page counter then you can use the &lt;code&gt;PagingRequest&lt;/code&gt; like this.
Where you can use the internal &lt;code&gt;PagingRequest.Count&lt;/code&gt; counter to manage the row index. &lt;code&gt;start&lt;/code&gt; is used to set the initial counter value.
The process continues until the API returns an empty response.&lt;/p&gt;
&lt;div class="lang-xml editor-colors"&gt;&lt;div style="color:Black;background-color:White;"&gt;&lt;pre&gt;
&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;PagingRequest&lt;/span&gt; &lt;span style="color:Red;"&gt;start&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;0&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;path&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;data&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
	&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Fetch&lt;/span&gt; &lt;span style="color:Red;"&gt;url&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;{URL}/app/list/{Datasource.Name}?skip={PagingRequest.Count}&amp;amp;amp;take={PageSize}&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
		&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;DataTableTransform&lt;/span&gt; &lt;span style="color:Red;"&gt;path&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;data&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
	&lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Fetch&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
&lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;PagingRequest&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;h3 id="indexed-paging"&gt;Indexed Paging&lt;/h3&gt;
&lt;p&gt;Indexed paging is based on paging through rows using an Index. Each iteration of the page we move the index along according to the page size parameter value. The paging stops when the API returns an empty response or HTTP status code 204.&lt;/p&gt;
&lt;p&gt;So you will see requests like this&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;GET /app/list/products?startIndex=0&amp;amp;endIndex=10&lt;/li&gt;
&lt;li&gt;GET /app/list/products?startIndex=11&amp;amp;endIndex=20&lt;/li&gt;
&lt;li&gt;GET /app/list/products?startIndex=21&amp;amp;endIndex=30&lt;/li&gt;
&lt;li&gt;GET /app/list/products?startIndex=31&amp;amp;endIndex=40&lt;/li&gt;
&lt;/ul&gt;
&lt;div class="lang-xml editor-colors"&gt;&lt;div style="color:Black;background-color:White;"&gt;&lt;pre&gt;
&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;PagingRequest&lt;/span&gt; &lt;span style="color:Red;"&gt;page-size&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;{PageSize}&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
    &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Fetch&lt;/span&gt; &lt;span style="color:Red;"&gt;url&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;{URL}/app/list/{Datasource.Name}?startIndex={PagingRequest.StartPageIndex}&amp;amp;endIndex={PagingRequest.EndPageIndex}&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt; 
        &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;DataTableTransform&lt;/span&gt; &lt;span style="color:Red;"&gt;path&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;data&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
    &lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Fetch&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
&lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;PagingRequest&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;h2 id="parent-child"&gt;Parent Child&lt;/h2&gt;
&lt;p&gt;Perhaps you need to call the API multiple times based on the results of an API call. In this case we have the &lt;code&gt;ForEach&lt;/code&gt; function which can be used to loop over the results.
In the example below we get a List of Suppliers and then Get a List of Products for each of those Suppliers whilst still using a PagingRequest.&lt;/p&gt;
&lt;div class="lang-xml editor-colors"&gt;&lt;div style="color:Black;background-color:White;"&gt;&lt;pre&gt;
&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Fetch&lt;/span&gt; &lt;span style="color:Red;"&gt;url&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;{URL}/app/list/suppliers&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
  &lt;span style="color:Green;"&gt;&amp;lt;!-- For Each SupplierID get the related Products --&amp;gt;&lt;/span&gt;
  &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;ForEach&lt;/span&gt; &lt;span style="color:Red;"&gt;path&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;data&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
    &lt;span style="color:Green;"&gt;&amp;lt;!-- Handle Paging for the Product List --&amp;gt;&lt;/span&gt;
    &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;PagingRequest&lt;/span&gt; &lt;span style="color:Red;"&gt;path&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;data&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;start&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;1&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;next-path&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;nextpage&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
      &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Fetch&lt;/span&gt; &lt;span style="color:Red;"&gt;url&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;{URL}/app/list/products?filter=SupplierID%20eq%20{$SupplierID}&amp;amp;amp;page={PagingRequest.Page}&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
        &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;DataTableTransform&lt;/span&gt; &lt;span style="color:Red;"&gt;path&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;data&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
      &lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Fetch&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
    &lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;PagingRequest&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
  &lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;ForEach&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
&lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Fetch&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;h2 id="stacked-response"&gt;Stacked Response&lt;/h2&gt;
&lt;p&gt;Perhaps you need to extract multiple parts from the Json Response, in this example we pull out the all the bank holidays from UK gov feed and assign a static value to the region column.&lt;/p&gt;
&lt;div class="lang-xml editor-colors"&gt;&lt;div style="color:Black;background-color:White;"&gt;&lt;pre&gt;
&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Fetch&lt;/span&gt; &lt;span style="color:Red;"&gt;url&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;https://www.gov.uk/bank-holidays.json&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
  &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;DataTableTransform&lt;/span&gt; &lt;span style="color:Red;"&gt;path&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;england-and-wales.events&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
    &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;ColumnMap&lt;/span&gt; &lt;span style="color:Red;"&gt;value&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;england-and-wales&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;to&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;region&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
  &lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;DataTableTransform&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
  &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;DataTableTransform&lt;/span&gt; &lt;span style="color:Red;"&gt;path&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;scotland.events&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
    &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;ColumnMap&lt;/span&gt; &lt;span style="color:Red;"&gt;value&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;scotland&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;to&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;region&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
  &lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;DataTableTransform&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
  &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;DataTableTransform&lt;/span&gt; &lt;span style="color:Red;"&gt;path&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;northern-ireland.events&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
    &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;ColumnMap&lt;/span&gt; &lt;span style="color:Red;"&gt;value&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;northern-ireland&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;to&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;region&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
  &lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;DataTableTransform&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
&lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Fetch&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;h2 id="post-request"&gt;Post Request&lt;/h2&gt;
&lt;p&gt;If you need to Post data to your endpoint rather than a Get request. You can specify the method of the request and add a body.&lt;/p&gt;
&lt;div class="lang-xml editor-colors"&gt;&lt;div style="color:Black;background-color:White;"&gt;&lt;pre&gt;
&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Action&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;GetDataTable&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
    &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Fetch&lt;/span&gt; &lt;span style="color:Red;"&gt;method&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;POST&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;url&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;{URL}&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
        &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Body&lt;/span&gt; &lt;span style="color:Red;"&gt;content-type&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;application/x-www-form-urlencoded&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
            &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Item&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;Item1&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;value&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;value1&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
            &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Item&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;Item2&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;value&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;value2&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
        &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Body&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
        &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;DataTableTransform&lt;/span&gt; &lt;span style="color:Red;"&gt;path&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;value&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
    &lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Fetch&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
&lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Action&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;p&gt;You can also specify the Body as a raw body value by using the &lt;code&gt;BodyContent&lt;/code&gt; element.&lt;/p&gt;
&lt;div class="lang-xml editor-colors"&gt;&lt;div style="color:Black;background-color:White;"&gt;&lt;pre&gt;
&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Action&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;GetDataTable&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
    &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Fetch&lt;/span&gt; &lt;span style="color:Red;"&gt;method&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;POST&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;url&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;{URL}&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
        &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;BodyContent&lt;/span&gt; &lt;span style="color:Red;"&gt;content-type&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;application/x-www-form-urlencoded&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
            Item1=value1&amp;amp;Item2=value2
        &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;BodyContent&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
        &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;DataTableTransform&lt;/span&gt; &lt;span style="color:Red;"&gt;path&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;value&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
    &lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Fetch&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
&lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Action&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;h2 id="open-file"&gt;Open File&lt;/h2&gt;
&lt;p&gt;You can read json from a local file as well by using the &lt;code&gt;OpenFile&lt;/code&gt; action and specifying the path to the file.&lt;/p&gt;
&lt;div class="lang-xml editor-colors"&gt;&lt;div style="color:Black;background-color:White;"&gt;&lt;pre&gt;
&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Datasource&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;fxrates&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
  &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Action&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;GetDataSchema&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
    &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;StaticSchemaMap&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
      &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Column&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;Currency&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;data-type&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;System.String&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;key&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;true&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
      &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Column&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;Rate&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;data-type&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;System.Decimal&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
    &lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;StaticSchemaMap&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
  &lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Action&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
  &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Action&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;GetDataTable&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
    &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;ReadFile&lt;/span&gt; &lt;span style="color:Red;"&gt;path&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;fxrates.json&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
      &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;DataTableTransform&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
    &lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;ReadFile&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
  &lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Action&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
&lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Datasource&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;h2 id="authentication"&gt;Authentication&lt;/h2&gt;
&lt;p&gt;We have several Authentication options where you only need to specify the authentication scheme to use in the Authentication section. All subsequent requests will then use the authentication details.&lt;/p&gt;
&lt;h3 id="basic-authentication"&gt;Basic Authentication&lt;/h3&gt;
&lt;p&gt;You can specify that the connector uses Basic Authentication by adding the &lt;code&gt;BasicAuth&lt;/code&gt; authentication scheme.&lt;/p&gt;
&lt;div class="lang-xml editor-colors"&gt;&lt;div style="color:Black;background-color:White;"&gt;&lt;pre&gt;
&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Authentication&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
  &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;BasicAuth&lt;/span&gt; &lt;span style="color:Red;"&gt;username&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;username&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;password&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;password&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
&lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Authentication&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;h3 id="oauth2-authentication"&gt;OAuth2 Authentication&lt;/h3&gt;
&lt;p&gt;You can specify that the connector uses OAuth either &lt;code&gt;client_credentials&lt;/code&gt; flow or &lt;code&gt;authorization_code&lt;/code&gt; flow by adding the &lt;code&gt;OAuth2&lt;/code&gt; authentication scheme.&lt;/p&gt;
&lt;div class="lang-xml editor-colors"&gt;&lt;div style="color:Black;background-color:White;"&gt;&lt;pre&gt;
&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Authentication&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
  &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;OAuth2&lt;/span&gt; &lt;span style="color:Red;"&gt;authorise-url&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;{authorize-url}&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;token-url&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;{token-url}&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;client-id&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;{client-id}&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;client-secret&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;{client-secret}&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;grant-type&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;authorization_code&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;scope&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;{scope}&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;prompt&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;select_account&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
&lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Authentication&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;p&gt;You can now use certificate based OAuth2 flows via the &lt;code&gt;certificate-thumbprint&lt;/code&gt; attribute.&lt;/p&gt;
&lt;div class="lang-xml editor-colors"&gt;&lt;div style="color:Black;background-color:White;"&gt;&lt;pre&gt;
&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Authentication&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
    &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;OAuth2&lt;/span&gt; &lt;span style="color:Red;"&gt;token-url&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;{token-url}&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;client-id&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;{client-id}&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;grant-type&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;client_credentials&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;scope&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;{scope}&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;certificate-thumbprint&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;{thumbprint}&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
&lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Authentication&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;h3 id="http-headers"&gt;Http Headers&lt;/h3&gt;
&lt;p&gt;You can add HttpHeaders to the request by adding multiple &lt;code&gt;HttpHeader&lt;/code&gt; types to the authentication scheme.&lt;/p&gt;
&lt;div class="lang-xml editor-colors"&gt;&lt;div style="color:Black;background-color:White;"&gt;&lt;pre&gt;
&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Authentication&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
  &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;HttpHeader&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;OData-Version&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;value&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;4.0&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
  &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;HttpHeader&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;OData-MaxVersion&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;value&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;4.0&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
&lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Authentication&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;h3 id="authorization-header"&gt;Authorization Header&lt;/h3&gt;
&lt;p&gt;You can specify an Http &lt;code&gt;Authorization&lt;/code&gt; Header like this.&lt;/p&gt;
&lt;div class="lang-xml editor-colors"&gt;&lt;div style="color:Black;background-color:White;"&gt;&lt;pre&gt;
&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Authentication&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
 &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;AuthorizationHeader&lt;/span&gt; &lt;span style="color:Red;"&gt;type&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;Bearer&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;token&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;{api-token}&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
&lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Authentication&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;h3 id="using-project-automation"&gt;Using Project Automation&lt;/h3&gt;
&lt;p&gt;Should you require calling an API to get an access token but the API is not OAuth2 but some home grown API then you
can use Project Automation to call the API manually and setup the &lt;code&gt;Authorization Header&lt;/code&gt;.&lt;/p&gt;
&lt;p&gt;Enable Project Automation and implement the &lt;code&gt;Start()&lt;/code&gt; method like this. This will call the Authentication API and add the access token to the API definition at runtime.&lt;/p&gt;
&lt;div class="lang-csharp editor-colors"&gt;&lt;div style="color:Black;background-color:White;"&gt;&lt;pre&gt;
&lt;span style="color:Blue;"&gt;public&lt;/span&gt; &lt;span style="color:Blue;"&gt;override&lt;/span&gt; &lt;span style="color:Blue;"&gt;void&lt;/span&gt; Start()
{
	&lt;span style="color:Blue;"&gt;var&lt;/span&gt; helper = &lt;span style="color:Blue;"&gt;new&lt;/span&gt;  HttpWebRequestHelper(); 
	&lt;span style="color:Blue;"&gt;var&lt;/span&gt; response = helper.PostRequestAsJson(&lt;span style="color:Blue;"&gt;new&lt;/span&gt; { email = &lt;span style="color:#A31515;"&gt;&amp;quot;username&amp;quot;&lt;/span&gt;, password = &lt;span style="color:#A31515;"&gt;&amp;quot;password&amp;quot;&lt;/span&gt; }, &lt;span style="color:#A31515;"&gt;&amp;quot;https://localhost:2026/api/login&amp;quot;&lt;/span&gt;); 
	
	DataSourceA.AuthorizationHeader.Token = response[&lt;span style="color:#A31515;"&gt;&amp;quot;access_token&amp;quot;&lt;/span&gt;]?.ToObject&amp;lt;&lt;span style="color:Blue;"&gt;string&lt;/span&gt;&amp;gt;();            
}
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;p&gt;Or you could manually call an OAuth endpoint like this to set the Token on the &lt;code&gt;AuthorizationHeader&lt;/code&gt;.&lt;/p&gt;
&lt;div class="lang-csharp editor-colors"&gt;&lt;div style="color:Black;background-color:White;"&gt;&lt;pre&gt;
&lt;span style="color:Blue;"&gt;public&lt;/span&gt; &lt;span style="color:Blue;"&gt;override&lt;/span&gt; &lt;span style="color:Blue;"&gt;void&lt;/span&gt; Start()
{
	&lt;span style="color:Blue;"&gt;var&lt;/span&gt; helper = &lt;span style="color:Blue;"&gt;new&lt;/span&gt; HttpWebRequestHelper();
	&lt;span style="color:Blue;"&gt;var&lt;/span&gt; result = helper.PostRequestAsString(&lt;span style="color:Blue;"&gt;new&lt;/span&gt; Dictionary&amp;lt;&lt;span style="color:Blue;"&gt;string&lt;/span&gt;, &lt;span style="color:Blue;"&gt;string&lt;/span&gt;&amp;gt; {  { &lt;span style="color:#A31515;"&gt;&amp;quot;client_id&amp;quot;&lt;/span&gt;, &lt;span style="color:#A31515;"&gt;&amp;quot;client_xyz_&amp;quot;&lt;/span&gt; }, { &lt;span style="color:#A31515;"&gt;&amp;quot;client_secret&amp;quot;&lt;/span&gt;, &lt;span style="color:#A31515;"&gt;&amp;quot;secret_xyz_&amp;quot;&lt;/span&gt;}, { &lt;span style="color:#A31515;"&gt;&amp;quot;grant_type&amp;quot;&lt;/span&gt;, &lt;span style="color:#A31515;"&gt;&amp;quot;client_credentials&amp;quot;&lt;/span&gt; } }, HttpWebRequestHelper.MimeTypeApplicationWwwFormUrlEncoded, &lt;span style="color:#A31515;"&gt;&amp;quot;http://localhost:8080/oauth/token&amp;quot;&lt;/span&gt;);
		
	DataSourceA.AuthorizationHeader.Token = (&lt;span style="color:Blue;"&gt;string&lt;/span&gt;)HttpWebRequestHelper.FromJsonToDictionary(result)[&lt;span style="color:#A31515;"&gt;&amp;quot;access_token&amp;quot;&lt;/span&gt;];
}

&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;h2 id="column-mapping"&gt;Column Mapping&lt;/h2&gt;
&lt;p&gt;The &lt;code&gt;DataTableTransform&lt;/code&gt; action will automatically map columns from the json response to the DataTable based on the schema map mapping the columns by name (case-sensitive).
If you want to manage the mapping or add additional mappings then you can add &lt;code&gt;ColumnMap&lt;/code&gt; nodes to the &lt;code&gt;DataTableTransform&lt;/code&gt;.&lt;/p&gt;
&lt;p&gt;For example mapping a Json node &lt;code&gt;Currency&lt;/code&gt; to a Schema Column named &lt;code&gt;CCY&lt;/code&gt;. The Path here is a JsonPath expression and therefore can select complex nodes.&lt;/p&gt;
&lt;div class="lang-xml editor-colors"&gt;&lt;div style="color:Black;background-color:White;"&gt;&lt;pre&gt;
&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;DataTableTransform&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
 &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;ColumnMap&lt;/span&gt; &lt;span style="color:Red;"&gt;path&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;Currency&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;to&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;CCY&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
&lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;DataTableTransform&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;p&gt;If you want to map a static value to a column you can also do this with the &lt;code&gt;value&lt;/code&gt; attribute like this.&lt;/p&gt;
&lt;div class="lang-xml editor-colors"&gt;&lt;div style="color:Black;background-color:White;"&gt;&lt;pre&gt;
&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;DataTableTransform&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
 &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;ColumnMap&lt;/span&gt; &lt;span style="color:Red;"&gt;value&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;1&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;to&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;version&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
&lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;DataTableTransform&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;p&gt;If you need to pull a value from the parent of the current json context. You can use the &lt;code&gt;parent-path&lt;/code&gt; attribute.&lt;/p&gt;
&lt;div class="lang-xml editor-colors"&gt;&lt;div style="color:Black;background-color:White;"&gt;&lt;pre&gt;
&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Action&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;GetDataTable&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
  &lt;span style="color:Green;"&gt;&amp;lt;!-- Fetch the list of invoices from a json file --&amp;gt;&lt;/span&gt;
  &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;ReadFile&lt;/span&gt; &lt;span style="color:Red;"&gt;path&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;invoices.json&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
   &lt;span style="color:Green;"&gt;&amp;lt;!-- For each invoice, get the related Line Items --&amp;gt;&lt;/span&gt;
   &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;ForEach&lt;/span&gt; &lt;span style="color:Red;"&gt;path&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;invoices&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
    &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;DataTableTransform&lt;/span&gt; &lt;span style="color:Red;"&gt;path&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;line_items&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
     &lt;span style="color:Green;"&gt;&amp;lt;!-- Get the Invoice ID from the parent element --&amp;gt;&lt;/span&gt;
     &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;ColumnMap&lt;/span&gt; &lt;span style="color:Red;"&gt;parent-path&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;id&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;to&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;invoice_id&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;				
      &lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;DataTableTransform&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
   &lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;ForEach&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
 &lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;ReadFile&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
&lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Action&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;p&gt;If you need to select part of a value from a string inside an json element you can use a Regular Expression with the &lt;code&gt;expression&lt;/code&gt; attribute.
The first group match will be returned as the value for the column.&lt;/p&gt;
&lt;div class="lang-xml editor-colors"&gt;&lt;div style="color:Black;background-color:White;"&gt;&lt;pre&gt;
&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;DataTableTransform&lt;/span&gt; &lt;span style="color:Red;"&gt;path&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;contacts&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
    &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;ColumnMap&lt;/span&gt; &lt;span style="color:Red;"&gt;path&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;address&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;to&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;_internalID&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;expression&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;R:(\d{3,})&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
&lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;DataTableTransform&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;p&gt;To select the OData ETag element use this format because of the @ in the name.&lt;/p&gt;
&lt;div class="lang-xml editor-colors"&gt;&lt;div style="color:Black;background-color:White;"&gt;&lt;pre&gt;
&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;ColumnMap&lt;/span&gt; &lt;span style="color:Red;"&gt;path&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;$.[&amp;#39;@odata.etag&amp;#39;]&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;to&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;etag&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;h2 id="debugging"&gt;Debugging&lt;/h2&gt;
&lt;p&gt;You can add a column to the &lt;code&gt;StaticSchemaMap&lt;/code&gt; to hold a copy of the row json object so you can see the raw json per row in the Data Sync data preview. You then add a &lt;code&gt;ColumnMap&lt;/code&gt; to the &lt;code&gt;DataTableTransform&lt;/code&gt; to map the json to the column like this below.&lt;/p&gt;
&lt;div class="lang-xml editor-colors"&gt;&lt;div style="color:Black;background-color:White;"&gt;&lt;pre&gt;
&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Datasource&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;fxrates&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
  &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Action&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;GetDataSchema&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
    &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;StaticSchemaMap&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
      &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Column&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;Currency&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;data-type&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;System.String&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;key&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;true&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
      &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Column&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;Rate&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;data-type&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;System.Decimal&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
      &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Column&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;__json&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;data-type&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;JToken&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
    &lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;StaticSchemaMap&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
  &lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Action&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
  &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Action&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;GetDataTable&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
    &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;ReadFile&lt;/span&gt; &lt;span style="color:Red;"&gt;path&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;fxrates.json&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
      &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;DataTableTransform&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
        &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;ColumnMap&lt;/span&gt; &lt;span style="color:Red;"&gt;path&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;$&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;to&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;__json&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
      &lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;DataTableTransform&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
    &lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;ReadFile&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
  &lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Action&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
&lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Datasource&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;p&gt;You can also trace to the Data Sync Output window the entire Json Document by using the &lt;code&gt;TraceElement&lt;/code&gt; action type like this.&lt;/p&gt;
&lt;div class="lang-xml editor-colors"&gt;&lt;div style="color:Black;background-color:White;"&gt;&lt;pre&gt;
&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Datasource&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;fxrates&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
  &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Action&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;GetDataSchema&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
    &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;StaticSchemaMap&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
      &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Column&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;Currency&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;data-type&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;System.String&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;key&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;true&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
      &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Column&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;Rate&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;data-type&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;System.Decimal&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
    &lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;StaticSchemaMap&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
  &lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Action&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
  &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Action&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;GetDataTable&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
    &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;ReadFile&lt;/span&gt; &lt;span style="color:Red;"&gt;path&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;fxrates.json&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
      &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;DataTableTransform&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
      &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;TraceElement&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
    &lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;ReadFile&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
  &lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Action&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
&lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Datasource&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;h2 id="putting-it-all-together"&gt;Putting it all together&lt;/h2&gt;
&lt;p&gt;The example below puts everything together to create a OAuth2 authenticated JSON API connection to return a Products dataset by Looking up the Products for Each Supplier and paging the returned results.&lt;/p&gt;
&lt;div class="lang-xml editor-colors"&gt;&lt;div style="color:Black;background-color:White;"&gt;&lt;pre&gt;
&lt;span style="color:Green;"&gt;&amp;lt;!--
An Example REST API connector which will use 2 requests
 * First to return a List of Suppliers
 * Second to loop around the Suppliers and return a List of Products for each Supplier.
--&amp;gt;&lt;/span&gt;
&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Connector&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;Simego Web API Connector&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;description&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;Connect to Simego Web API&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;version&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;1.0&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
  &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Parameters&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
    &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Parameter&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;URL&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;value&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;https://demo.online.simego.com&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
    &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Parameter&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;PageSize&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;value&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;10&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
    &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Parameter&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;ClientID&amp;quot; value=&amp;quot;&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
    &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Parameter&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;ClientSecret&amp;quot; value=&amp;quot;&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
  &lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Parameters&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
  &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Authentication&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
    &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;OAuth2&lt;/span&gt; &lt;span style="color:Red;"&gt;token-url&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;{URL}/oauth/token&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;client-id&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;{ClientID}&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;client-secret&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;{ClientSecret}&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;grant-type&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;client_credentials&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
  &lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Authentication&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
  &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Datasources&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
    &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Datasource&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;Products&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
      &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Action&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;GetDataSchema&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
        &lt;span style="color:Green;"&gt;&amp;lt;!-- Define Static Schema for this Datasource --&amp;gt;&lt;/span&gt;
        &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;StaticSchemaMap&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
          &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Column&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;ProductID&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;data-type&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;System.Int32&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
          &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Column&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;SupplierID&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;data-type&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;System.Int32&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
          &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Column&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;ProductName&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;data-type&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;System.String&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
        &lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;StaticSchemaMap&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
      &lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Action&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
      &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Action&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;GetDataTable&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
        &lt;span style="color:Green;"&gt;&amp;lt;!-- First get a List of Supplier ID values --&amp;gt;&lt;/span&gt;
        &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Fetch&lt;/span&gt; &lt;span style="color:Red;"&gt;url&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;{URL}/app/list/suppliers?columns=SupplierID&amp;amp;amp;limit=1000&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
          &lt;span style="color:Green;"&gt;&amp;lt;!-- For Each SupplierID get the related Products --&amp;gt;&lt;/span&gt;
          &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;ForEach&lt;/span&gt; &lt;span style="color:Red;"&gt;path&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;data&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
            &lt;span style="color:Green;"&gt;&amp;lt;!-- Handle Paging for the Product List --&amp;gt;&lt;/span&gt;
            &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;PagingRequest&lt;/span&gt; &lt;span style="color:Red;"&gt;path&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;data&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;start&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;1&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;next-path&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;nextpage&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
              &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Fetch&lt;/span&gt; &lt;span style="color:Red;"&gt;url&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;{URL}/app/list/products?filter=SupplierID%20eq%20{$SupplierID}&amp;amp;amp;limit={PageSize}&amp;amp;amp;page={PagingRequest.Page}&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
                &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;DataTableTransform&lt;/span&gt; &lt;span style="color:Red;"&gt;path&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;data&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
              &lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Fetch&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
            &lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;PagingRequest&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
          &lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;ForEach&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
        &lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Fetch&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
      &lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Action&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
    &lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Datasource&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
  &lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Datasources&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
&lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Connector&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;p&gt;Or in this example we can call the Microsoft Graph API whilst using OAuth2 &lt;code&gt;authorization_code&lt;/code&gt; flow.&lt;/p&gt;
&lt;div class="lang-xml editor-colors"&gt;&lt;div style="color:Black;background-color:White;"&gt;&lt;pre&gt;
&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Connector&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;MS Graph API&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;description&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;Test quering Graph API via JSON API&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;version&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;1.0&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
  &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Parameters&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
    &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Parameter&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;url&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;value&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;https://graph.microsoft.com/beta&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
    &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Parameter&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;authorize-url&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;value&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;https://login.microsoftonline.com/cfb0271d-de7d-4732-9414-957ca405620b/oauth2/v2.0/authorize&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
    &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Parameter&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;token-url&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;value&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;https://login.microsoftonline.com/cfb0271d-de7d-4732-9414-957ca405620b/oauth2/v2.0/token&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
    &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Parameter&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;client-id&amp;quot; value=&amp;quot;&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
    &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Parameter&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;client-secret&amp;quot; value=&amp;quot;&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
    &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Parameter&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;scope&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;value&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;https://graph.microsoft.com/.default offline_access&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
  &lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Parameters&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
  &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Authentication&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
    &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;OAuth2&lt;/span&gt; &lt;span style="color:Red;"&gt;authorise-url&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;{authorize-url}&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;token-url&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;{token-url}&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;client-id&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;{client-id}&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;client-secret&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;{client-secret}&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;grant-type&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;authorization_code&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;scope&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;{scope}&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;prompt&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;select_account&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
    &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;HttpHeader&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;OData-Version&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;value&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;4.0&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
    &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;HttpHeader&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;OData-MaxVersion&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;value&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;4.0&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
  &lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Authentication&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
  &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Datasources&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
    &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Datasource&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;users&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
      &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Actions&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
        &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Action&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;GetDataSchema&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
          &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;StaticSchemaMap&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
            &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Column&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;id&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;type&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;System.String&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
            &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Column&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;givenName&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;type&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;System.String&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
            &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Column&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;mail&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;type&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;System.String&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
          &lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;StaticSchemaMap&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
        &lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Action&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
        &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Action&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;GetDataTable&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
          &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Fetch&lt;/span&gt; &lt;span style="color:Red;"&gt;url&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;{url}/users&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
            &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;DataTableTransform&lt;/span&gt; &lt;span style="color:Red;"&gt;path&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;value&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
          &lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Fetch&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
        &lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Action&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
      &lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Actions&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
    &lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Datasource&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
  &lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Datasources&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
&lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Connector&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;p&gt;Or in this example we call the Dynamics CRM/Dataverse API whilst using OAuth2 &lt;code&gt;authorization_code&lt;/code&gt; flow with a certificate.
This example shows how to implement data paging with an ODataV4 endpoint.&lt;/p&gt;
&lt;div class="lang-xml editor-colors"&gt;&lt;div style="color:Black;background-color:White;"&gt;&lt;pre&gt;
&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Connector&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;Dynamics365&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;description&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;quot; version=&amp;quot;1.0&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
	&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Authentication&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
		&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;HttpHeader&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;OData-Version&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;value&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;4.0&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
		&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;HttpHeader&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;OData-MaxVersion&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;value&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;4.0&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
		&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;HttpHeader&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;Prefer&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;value&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;odata.maxpagesize=10&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
		&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;OAuth2&lt;/span&gt; &lt;span style="color:Red;"&gt;token-url&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;https://login.microsoftonline.com/cfb0271d-de7d-4732-9414-957ca405620b/oauth2/v2.0/token&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;client-id&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;9a598195-082a-4d67-99b9-392c6c3e727d&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;grant-type&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;client_credentials&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;scope&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;https://simego.api.crm4.dynamics.com/.default&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;thumbprint&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;84FC24B07BFBCD08F0D5E5B45F&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
	&lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Authentication&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
	&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Datasources&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
		&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Datasource&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;accounts&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
			&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Action&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;GetDataSchema&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
				&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;StaticSchemaMap&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
					&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Column&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;accountid&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;data-type&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;System.Guid&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
					&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Column&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;name&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;data-type&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;System.String&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
					&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Column&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;etag&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;data-type&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;System.String&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
				&lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;StaticSchemaMap&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
			&lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Action&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
			&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Action&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;GetDataTable&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
				&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;PagingRequest&lt;/span&gt; &lt;span style="color:Red;"&gt;path&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;value&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;next&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;https://instance.api.crm4.dynamics.com/api/data/v9.2/accounts?$select=accountid,name&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;next-path&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;$.[&amp;#39;@odata.nextLink&amp;#39;]&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
					&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Fetch&lt;/span&gt; &lt;span style="color:Red;"&gt;url&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;{PagingRequest.Next}&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
						&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;DataTableTransform&lt;/span&gt; &lt;span style="color:Red;"&gt;path&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;value&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
							&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;ColumnMap&lt;/span&gt; &lt;span style="color:Red;"&gt;path&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;$.[&amp;#39;@odata.etag&amp;#39;]&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;to&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;etag&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
						&lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;DataTableTransform&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
					&lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Fetch&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
				&lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;PagingRequest&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
			&lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Action&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
		&lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Datasource&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
	&lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Datasources&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
&lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Connector&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;h2 id="writing-back"&gt;Writing Back&lt;/h2&gt;
&lt;p&gt;We have created a few different ways you can write back to the API. Since its likely you might need extra flexibility in how the data is formatted or sent to the API endpoint.&lt;/p&gt;
&lt;h3 id="identifier-column"&gt;Identifier Column&lt;/h3&gt;
&lt;p&gt;The first concept to understand is the role of the Identifier Column with Data Sync connectors.
These values are attached to the row internally within Data Sync and are a way to maintain the datasource PrimaryKey even when its not part of the Schema Map.
By maintaining this Identifier Column value it makes it possible to call UPDATE/DELETE actions on the target by the PrimaryKey value.&lt;/p&gt;
&lt;p&gt;To ensure that the &lt;code&gt;Identifier Column&lt;/code&gt; is set you need to specify the column from the Datasource which contains the Primary Key value like this within the &lt;code&gt;DataTableTransform&lt;/code&gt; element.&lt;/p&gt;
&lt;div class="lang-xml editor-colors"&gt;&lt;div style="color:Black;background-color:White;"&gt;&lt;pre&gt;
&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;DataTableTransform&lt;/span&gt; &lt;span style="color:Red;"&gt;path&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;data&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
  &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;IdentifierColumn&lt;/span&gt; &lt;span style="color:Red;"&gt;data-type&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;System.Int32&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;path&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;ProductID&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
&lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;DataTableTransform&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;h3 id="default-automatic-mode"&gt;Default Automatic Mode&lt;/h3&gt;
&lt;p&gt;This is the default &lt;strong&gt;no-code&lt;/strong&gt; option where the data is serialized to JSON and sent to the API endpoints using the URLs and Http Method(s) defined within the &lt;strong&gt;Writer&lt;/strong&gt; element.&lt;/p&gt;
&lt;div class="lang-xml editor-colors"&gt;&lt;div style="color:Black;background-color:White;"&gt;&lt;pre&gt;
&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Datasource&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;products&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
	&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Action&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;GetDataSchema&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
		&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;StaticSchemaMap&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
			&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Column&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;ProductID&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;data-type&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;System.Int32&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
			&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Column&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;ProductName&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;data-type&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;System.String&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
			&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Column&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;SupplierID&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;data-type&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;System.Int32&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
			&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Column&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;CategoryID&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;data-type&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;System.Int32&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
			&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Column&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;QuantityPerUnit&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;data-type&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;System.String&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
			&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Column&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;UnitPrice&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;data-type&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;System.Decimal&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
			&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Column&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;UnitsInStock&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;data-type&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;System.Int32&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
			&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Column&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;UnitsOnOrder&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;data-type&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;System.Int32&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
			&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Column&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;ReorderLevel&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;data-type&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;System.Int32&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
			&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Column&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;Discontinued&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;data-type&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;System.Boolean&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
		&lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;StaticSchemaMap&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
	&lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Action&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
	&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Action&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;GetDataTable&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
		&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;PagingRequest&lt;/span&gt; &lt;span style="color:Red;"&gt;start&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;0&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;path&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;data&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
			&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Fetch&lt;/span&gt; &lt;span style="color:Red;"&gt;url&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;{URL}/ListApi?skip={PagingRequest.Count}&amp;amp;amp;take={PageSize}&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
				&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;DataTableTransform&lt;/span&gt; &lt;span style="color:Red;"&gt;path&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;data&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
					&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;IdentifierColumn&lt;/span&gt; &lt;span style="color:Red;"&gt;data-type&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;System.Int32&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;path&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;ProductID&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
				&lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;DataTableTransform&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
			&lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Fetch&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
		&lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;PagingRequest&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
	&lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Action&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
	&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Writer&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;Default&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
		&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;AddItem&lt;/span&gt; &lt;span style="color:Red;"&gt;method&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;POST&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;url&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;{URL}/ListApi&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
		&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;UpdateItem&lt;/span&gt; &lt;span style="color:Red;"&gt;method&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;PUT&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;url&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;{URL}/ListApi/{Identifier0}&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
		&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;DeleteItem&lt;/span&gt; &lt;span style="color:Red;"&gt;method&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;DELETE&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;url&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;{URL}/ListApi/{Identifier0}&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
	&lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Writer&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
&lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Datasource&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;p&gt;For example this mode would send a HTTP response like this when Adding an item to the datasource.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;POST http://localhost:2026/ListApi
Content-Type:application/json
Accept:application/json
{&amp;quot;ProductID&amp;quot;:74,&amp;quot;ProductName&amp;quot;:&amp;quot;Longlife Tofu&amp;quot;,&amp;quot;SupplierID&amp;quot;:4,&amp;quot;CategoryID&amp;quot;:7,&amp;quot;QuantityPerUnit&amp;quot;:&amp;quot;5 kg pkg.&amp;quot;,&amp;quot;UnitPrice&amp;quot;:10.0,&amp;quot;UnitsInStock&amp;quot;:0,&amp;quot;UnitsOnOrder&amp;quot;:20,&amp;quot;ReorderLevel&amp;quot;:5,&amp;quot;Discontinued&amp;quot;:false}
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;Should the API require the data within another object the you can also specify a single path element via the &lt;code&gt;path&lt;/code&gt; attribute.&lt;/p&gt;
&lt;div class="lang-xml editor-colors"&gt;&lt;div style="color:Black;background-color:White;"&gt;&lt;pre&gt;
&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Writer&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;Default&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
	&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;AddItem&lt;/span&gt; &lt;span style="color:Red;"&gt;method&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;POST&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;url&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;{URL}/ListApi&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;path&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;data&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
	&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;UpdateItem&lt;/span&gt; &lt;span style="color:Red;"&gt;method&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;PUT&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;url&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;{URL}/ListApi/{Identifier0}&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;path&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;data&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
	&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;DeleteItem&lt;/span&gt; &lt;span style="color:Red;"&gt;method&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;DELETE&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;url&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;{URL}/ListApi/{Identifier0}&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
&lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Writer&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;p&gt;The Default writer will only include the changed column values in UPDATE actions in the Json Body. If you need to send all the column data again you can configure the writer by setting a mode value of &lt;code&gt;AllColumns&lt;/code&gt; this will send all column values as part of the JSON body in the request.&lt;/p&gt;
&lt;div class="lang-xml editor-colors"&gt;&lt;div style="color:Black;background-color:White;"&gt;&lt;pre&gt;
&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Writer&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;Default&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
    &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;AddItem&lt;/span&gt; &lt;span style="color:Red;"&gt;method&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;POST&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;url&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;{URL}/ListApi&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
    &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;UpdateItem&lt;/span&gt; &lt;span style="color:Red;"&gt;method&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;PUT&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;url&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;{URL}/ListApi/{Identifier0}&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;mode&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;AllColumns&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
    &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;DeleteItem&lt;/span&gt; &lt;span style="color:Red;"&gt;method&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;DELETE&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;url&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;{URL}/ListApi/{Identifier0}&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
&lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Writer&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;p&gt;To send only the Key column values from the Schema Mapping as part of the JSON body for UPDATE set the mode to &lt;code&gt;AllKeys&lt;/code&gt;.&lt;/p&gt;
&lt;div class="lang-xml editor-colors"&gt;&lt;div style="color:Black;background-color:White;"&gt;&lt;pre&gt;
&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Writer&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;Default&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
    &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;AddItem&lt;/span&gt; &lt;span style="color:Red;"&gt;method&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;POST&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;url&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;{URL}/ListApi&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
    &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;UpdateItem&lt;/span&gt; &lt;span style="color:Red;"&gt;method&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;PUT&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;url&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;{URL}/ListApi/{Identifier0}&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;mode&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;AllKeys&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
    &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;DeleteItem&lt;/span&gt; &lt;span style="color:Red;"&gt;method&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;DELETE&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;url&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;{URL}/ListApi/{Identifier0}&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
&lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Writer&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;p&gt;To send only the Identifier column values set the mode to &lt;code&gt;AllIdentifiers&lt;/code&gt; and provide a comma separated list of column names in the &lt;code&gt;identifier-columns&lt;/code&gt; attribute to use for the Identifier column values.&lt;/p&gt;
&lt;div class="lang-xml editor-colors"&gt;&lt;div style="color:Black;background-color:White;"&gt;&lt;pre&gt;
&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Writer&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;Default&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
    &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;AddItem&lt;/span&gt; &lt;span style="color:Red;"&gt;method&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;POST&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;url&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;{URL}/ListApi&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
    &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;UpdateItem&lt;/span&gt; &lt;span style="color:Red;"&gt;method&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;PUT&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;url&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;{URL}/ListApi/{Identifier0}&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;mode&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;AllIdentifiers&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;identifier-columns&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;ProductID&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
    &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;DeleteItem&lt;/span&gt; &lt;span style="color:Red;"&gt;method&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;DELETE&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;url&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;{URL}/ListApi/{Identifier0}&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
&lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Writer&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;h3 id="project-automation-callbacks"&gt;Project Automation Callbacks&lt;/h3&gt;
&lt;p&gt;This mode allows for full control of how the API is called via a C# delegate callback on each item.
In this mode we setup the &lt;strong&gt;Writer&lt;/strong&gt; element with a name of &lt;strong&gt;Callback&lt;/strong&gt; and then configure the callback function in Project Automation.&lt;/p&gt;
&lt;div class="lang-xml editor-colors"&gt;&lt;div style="color:Black;background-color:White;"&gt;&lt;pre&gt;
&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Datasource&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;products&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
	&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Action&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;GetDataSchema&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
		&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;StaticSchemaMap&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
			&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Column&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;ProductID&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;data-type&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;System.Int32&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
			&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Column&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;ProductName&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;data-type&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;System.String&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
			&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Column&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;SupplierID&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;data-type&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;System.Int32&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
			&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Column&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;CategoryID&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;data-type&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;System.Int32&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
			&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Column&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;QuantityPerUnit&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;data-type&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;System.String&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
			&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Column&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;UnitPrice&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;data-type&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;System.Decimal&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
			&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Column&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;UnitsInStock&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;data-type&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;System.Int32&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
			&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Column&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;UnitsOnOrder&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;data-type&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;System.Int32&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
			&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Column&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;ReorderLevel&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;data-type&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;System.Int32&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
			&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Column&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;Discontinued&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;data-type&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;System.Boolean&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
		&lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;StaticSchemaMap&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
	&lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Action&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
	&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Action&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;GetDataTable&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
		&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;PagingRequest&lt;/span&gt; &lt;span style="color:Red;"&gt;start&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;0&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;path&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;data&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
			&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Fetch&lt;/span&gt; &lt;span style="color:Red;"&gt;url&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;{URL}/ListApi?skip={PagingRequest.Count}&amp;amp;amp;take={PageSize}&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
				&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;DataTableTransform&lt;/span&gt; &lt;span style="color:Red;"&gt;path&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;data&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
					&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;IdentifierColumn&lt;/span&gt; &lt;span style="color:Red;"&gt;data-type&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;System.Int32&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;path&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;ProductID&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
				&lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;DataTableTransform&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
			&lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Fetch&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
		&lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;PagingRequest&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
	&lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Action&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
	&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Writer&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;Callback&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
		&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;AddItem&lt;/span&gt; &lt;span style="color:Red;"&gt;url&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;{URL}/ListApi&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
		&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;UpdateItem&lt;/span&gt; &lt;span style="color:Red;"&gt;url&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;{URL}/ListApi/{Identifier0}&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
		&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;DeleteItem&lt;/span&gt; &lt;span style="color:Red;"&gt;url&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;{URL}/ListApi/{Identifier0}&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
	&lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Writer&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
&lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Datasource&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;p&gt;Within the &lt;code&gt;Start()&lt;/code&gt; method we setup the callback methods for ADD/UPDATE/DELETE. These will then be called during the synchronisation process for you to call the API.&lt;/p&gt;
&lt;p&gt;For convince we pass you an object for calling HTTP methods the &lt;strong&gt;HttpWebRequestHelper&lt;/strong&gt; with any authentication headers set and within the &lt;strong&gt;ProjectAutomationItemInfo&lt;/strong&gt; object we have the target URL in the &lt;strong&gt;Target&lt;/strong&gt; property.
The &lt;strong&gt;Data&lt;/strong&gt; property contains a &lt;code&gt;Dictionary&amp;lt;string, object&amp;gt;&lt;/code&gt; of the data converted to match the target schema.&lt;/p&gt;
&lt;p&gt;Therefore a simple implementation which would match the Default mode would be implemented like this.&lt;/p&gt;
&lt;div class="lang-csharp editor-colors"&gt;&lt;div style="color:Black;background-color:White;"&gt;&lt;pre&gt;
&lt;span style="color:Blue;"&gt;public&lt;/span&gt; &lt;span style="color:Blue;"&gt;override&lt;/span&gt; &lt;span style="color:Blue;"&gt;void&lt;/span&gt; Start()
{		
	DataSourceB.SetWriterCallback(AddItem, UpdateItem, DeleteItem);
}

&lt;span style="color:Blue;"&gt;public&lt;/span&gt; &lt;span style="color:Blue;"&gt;void&lt;/span&gt; AddItem(HttpWebRequestHelper helper, ProjectAutomationItemInfo info)
{
	helper.PostRequestAsJson(info.Data, info.Target);
}

&lt;span style="color:Blue;"&gt;public&lt;/span&gt; &lt;span style="color:Blue;"&gt;void&lt;/span&gt; UpdateItem(HttpWebRequestHelper helper, ProjectAutomationItemInfo info)
{
	helper.PutRequestAsJson(info.Data, info.Target);
}

&lt;span style="color:Blue;"&gt;public&lt;/span&gt; &lt;span style="color:Blue;"&gt;void&lt;/span&gt; DeleteItem(HttpWebRequestHelper helper, ProjectAutomationItemInfo info)
{
	helper.DeleteRequestAsJson(&lt;span style="color:Blue;"&gt;null&lt;/span&gt;, info.Target);
}
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;h3 id="project-automation-batch-callback"&gt;Project Automation Batch Callback&lt;/h3&gt;
&lt;blockquote&gt;
&lt;p&gt;Requires Data Sync Version 6.0.3398&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;This mode allows for full control of how the API is called in batches via a C# delegate callback on each batch of items.
In this mode we setup the &lt;strong&gt;Writer&lt;/strong&gt; element with a name of &lt;strong&gt;BatchCallback&lt;/strong&gt; and then configure the callback functions in Project Automation.&lt;/p&gt;
&lt;p&gt;In this example the API expects an Array of items like this below. Therefore we will need to wrap the array of results into an anonymous object to add the &lt;code&gt;items&lt;/code&gt; element.&lt;/p&gt;
&lt;div class="lang-json editor-colors"&gt;&lt;div style="color:Black;background-color:White;"&gt;&lt;pre&gt;
{
    &lt;span style="color:#A31515;"&gt;&amp;quot;items&amp;quot;&lt;/span&gt;: [
        { ... },
        { ... }
    ]
}
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;p&gt;Since we need to include the item identifier in the body of the request rather than the URL we use the mode option of &lt;code&gt;AllIdentifiers&lt;/code&gt; to ensure that the items ID is included in UPDATE and DELETE operations.&lt;/p&gt;
&lt;p&gt;To Adjust the size of the Batch include a Parameter named &lt;code&gt;UpdateBatchSize&lt;/code&gt; where you can specify the size of each batch of items.&lt;/p&gt;
&lt;div class="lang-xml editor-colors"&gt;&lt;div style="color:Black;background-color:White;"&gt;&lt;pre&gt;
&lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Connector&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;Simego Web API Connector&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;description&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;Connect to Simego Web API&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;version&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;1.0&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
  &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Parameters&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
    &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Parameter&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;URL&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;value&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;http://localhost:8080&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
    &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Parameter&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;PageSize&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;value&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;10&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
    &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Parameter&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;UpdateBatchSize&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;value&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;10&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
  &lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Parameters&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
  &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Datasources&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
    &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Datasource&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;Products&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
      &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Action&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;GetDataSchema&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
        &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;StaticSchemaMap&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
          &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Column&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;ProductID&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;data-type&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;System.Int32&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
          &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Column&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;ProductName&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;data-type&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;System.String&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
          &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Column&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;SupplierID&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;data-type&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;System.Int32&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
          &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Column&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;CategoryID&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;data-type&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;System.Int32&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
          &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Column&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;QuantityPerUnit&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;data-type&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;System.String&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
          &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Column&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;UnitPrice&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;data-type&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;System.Decimal&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
          &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Column&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;UnitsInStock&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;data-type&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;System.Int32&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
          &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Column&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;UnitsOnOrder&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;data-type&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;System.Int32&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
          &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Column&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;ReorderLevel&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;data-type&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;System.Int32&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
          &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Column&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;Discontinued&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;data-type&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;System.Boolean&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
        &lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;StaticSchemaMap&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
      &lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Action&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
      &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Action&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;GetDataTable&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
        &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;PagingRequest&lt;/span&gt; &lt;span style="color:Red;"&gt;path&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;data&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;start&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;1&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;next-path&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;nextpage&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
          &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Fetch&lt;/span&gt; &lt;span style="color:Red;"&gt;url&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;{URL}/app/list/{Datasource.Name}?limit={PageSize}&amp;amp;amp;page={PagingRequest.Page}&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
            &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;DataTableTransform&lt;/span&gt; &lt;span style="color:Red;"&gt;path&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;data&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
              &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;IdentifierColumn&lt;/span&gt; &lt;span style="color:Red;"&gt;data-type&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;System.Int32&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;path&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;WS_ID&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
            &lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;DataTableTransform&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
          &lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Fetch&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
        &lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;PagingRequest&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
      &lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Action&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
      &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Writer&lt;/span&gt; &lt;span style="color:Red;"&gt;name&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;BatchCallback&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
        &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;AddItem&lt;/span&gt; &lt;span style="color:Red;"&gt;url&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;{URL}/app/list/{Datasource.Name}&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
        &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;UpdateItem&lt;/span&gt; &lt;span style="color:Red;"&gt;url&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;{URL}/app/list/{Datasource.Name}&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;mode&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;AllIdentifiers&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;identifier-columns&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;WS_ID&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
        &lt;span style="color:Blue;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#A31515;"&gt;DeleteItem&lt;/span&gt; &lt;span style="color:Red;"&gt;url&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;{URL}/app/list/{Datasource.Name}&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;mode&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;AllIdentifiers&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Red;"&gt;identifier-columns&lt;/span&gt;&lt;span style="color:Blue;"&gt;=&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt;&lt;span style="color:Blue;"&gt;WS_ID&lt;/span&gt;&lt;span style="color:Black;"&gt;&amp;quot;&lt;/span&gt; &lt;span style="color:Blue;"&gt;/&amp;gt;&lt;/span&gt;
      &lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Writer&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
    &lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Datasource&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
  &lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Datasources&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
&lt;span style="color:Blue;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#A31515;"&gt;Connector&lt;/span&gt;&lt;span style="color:Blue;"&gt;&amp;gt;&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;div class="lang-csharp editor-colors"&gt;&lt;div style="color:Black;background-color:White;"&gt;&lt;pre&gt;
&lt;span style="color:Blue;"&gt;public&lt;/span&gt; &lt;span style="color:Blue;"&gt;override&lt;/span&gt; &lt;span style="color:Blue;"&gt;void&lt;/span&gt; Start()
{		
	DataSourceB.SetWriterBatchCallback(AddItem, UpdateItem, DeleteItem);
}

&lt;span style="color:Blue;"&gt;public&lt;/span&gt; &lt;span style="color:Blue;"&gt;void&lt;/span&gt; AddItem(HttpWebRequestHelper helper, ProjectAutomationBatchInfo info)
{
	helper.PostRequestAsJson(&lt;span style="color:Blue;"&gt;new&lt;/span&gt; { items = info.Data }, info.Target);
}

&lt;span style="color:Blue;"&gt;public&lt;/span&gt; &lt;span style="color:Blue;"&gt;void&lt;/span&gt; UpdateItem(HttpWebRequestHelper helper, ProjectAutomationBatchInfo info)
{
	helper.PutRequestAsJson(&lt;span style="color:Blue;"&gt;new&lt;/span&gt; { items = info.Data }, info.Target);
}

&lt;span style="color:Blue;"&gt;public&lt;/span&gt; &lt;span style="color:Blue;"&gt;void&lt;/span&gt; DeleteItem(HttpWebRequestHelper helper, ProjectAutomationBatchInfo info)
{		
	helper.DeleteRequestAsJson(&lt;span style="color:Blue;"&gt;new&lt;/span&gt; { items = info.Data }, info.Target);
}
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;p&gt;Since we are processing items in Batch this mode does not support Project Automation Item events. If you need to do further processing we would suggest you do that in the callback function instead.&lt;/p&gt;
&lt;h2 id="conclusion"&gt;Conclusion&lt;/h2&gt;
&lt;p&gt;In closing we hope you will be able to see how easy it will be to connect to JSON style APIs with Data Sync and this new connector.&lt;/p&gt;
</description>
      <source url="http://www.simego.com/blog">Team Blog</source>
      <pubDate>Tue, 30 Sep 2025 10:55:33 +0000</pubDate>
    </item>
    <item>
      <link>http://www.simego.com/blog/intro-to-mirrasql</link>
      <author>info@simego.com (Rebecca Allen)</author>
      <title>Introduction to MirraSQL</title>
      <description>&lt;p&gt;MirraSQL is a Windows command-line utility that imports Dataverse entities directly into SQL Server tables. It handles the connection to both systems, creates or updates your SQL schema to match Dataverse, and imports your records — all from a single command.&lt;/p&gt;
&lt;p&gt;MirraSQL is currently in beta. &lt;a href="https://www.simego.com/products/mirrasql"&gt;Download it here&lt;/a&gt; and send us your thoughts to help shape what gets built next.&lt;/p&gt;
&lt;h2 id="how-it-works"&gt;How It Works&lt;/h2&gt;
&lt;p&gt;MirraSQL connects to your Dataverse environment and your SQL Server database using a saved configuration profile. When you run an import, it:&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;Reads the entity schema from Dataverse&lt;/li&gt;
&lt;li&gt;Creates or updates the matching SQL Server table automatically&lt;/li&gt;
&lt;li&gt;Imports the records and reports progress in real time&lt;/li&gt;
&lt;/ol&gt;
&lt;p&gt;You don't need to pre-create your tables or define schemas. MirraSQL takes care of that, just make sure you have a database ready to hold the tables.&lt;/p&gt;
&lt;h2 id="use-cases"&gt;Use Cases&lt;/h2&gt;
&lt;p&gt;Below you can see a couple of use cases where we think MirraSQL will prove beneficial.&lt;/p&gt;
&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Use Case&lt;/th&gt;
&lt;th&gt;Benefit&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;Reporting and BI&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Run Power BI, SSRS, or Excel reports against SQL instead of your live Dataverse — meaning faster reports and lower API usage&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;Data Backup and Archiving&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Maintain a queryable SQL snapshot of your Dataverse data that doesn't depend on Dataverse availability&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;Feeding a Data Warehouse&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Get your raw Dataverse entities into a staging schema ready for transformation into your dimensional model&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;Custom Reporting&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Give your teams access to Dataverse data via standard SQL queries, without Dataverse API access or additional licences&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;Audit and Compliance&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Keep a SQL-based historical record of Dataverse data that can be queried and reported on with standard database tooling&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;Cross-System Analytics&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Join Dataverse data with ERP, HR, and finance records by getting everything in the same SQL database&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;Performance Offloading&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Move heavy analytical queries off Dataverse entirely to avoid API throttling and reduce load on your live environment&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;Supporting Legacy Systems&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Feed Dataverse data into older internal systems that can query SQL Server but cannot connect to Dataverse directly&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;Development and Testing&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Quickly populate DEV or UAT databases with a copy of production Dataverse data for integration testing or report development&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;Disaster Recovery Preparation&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Ensure a recent, queryable copy of your critical entities is always available in SQL Server if Dataverse becomes temporarily unavailable&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;
&lt;h2 id="system-requirements"&gt;System Requirements&lt;/h2&gt;
&lt;ul&gt;
&lt;li&gt;.NET Framework v4.8&lt;/li&gt;
&lt;li&gt;Windows Server 2016 - 2025&lt;/li&gt;
&lt;li&gt;Windows 10/11&lt;/li&gt;
&lt;li&gt;SQL Server 2016 or later (including Express edition)&lt;/li&gt;
&lt;li&gt;2 GB RAM&lt;/li&gt;
&lt;li&gt;1 CPU Core&lt;/li&gt;
&lt;li&gt;50 GB Disk Space&lt;/li&gt;
&lt;/ul&gt;
&lt;h2 id="installation"&gt;Installation&lt;/h2&gt;
&lt;p&gt;MirraSQL is available as a downloadable package for Windows Machines, making installation quick and easy. &lt;a href="https://www.simego.com/products/mirrasql"&gt;Dowload the installer package here&lt;/a&gt; to get up and running straight away.&lt;/p&gt;
&lt;p&gt;Once installed open a command prompt and type &lt;code&gt;MirraSQL&lt;/code&gt; to confirm it's working. You should see the help output with usage instructions and available commands. If it doesn't just search for the &lt;code&gt;MirraSQL.cmd&lt;/code&gt; program to open it.&lt;/p&gt;
&lt;h2 id="setting-up-your-connections"&gt;Setting Up Your Connections&lt;/h2&gt;
&lt;p&gt;Before running your first import you need to tell MirraSQL where to connect. You'll need two things:&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;Your &lt;strong&gt;Dataverse Connection String&lt;/strong&gt;&lt;/li&gt;
&lt;li&gt;Your &lt;strong&gt;SQL Server Connection String&lt;/strong&gt;&lt;/li&gt;
&lt;/ol&gt;
&lt;p&gt;If you're already running DataSync then you can grab these connection details from your Data Sync Connections.&lt;/p&gt;
&lt;h3 id="dataverse-connection-string"&gt;1. Dataverse Connection String&lt;/h3&gt;
&lt;p&gt;For the Dataverse Connection String you will need:&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;&lt;code&gt;AuthType=ClientSecret&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;The root URL of your Dataverse environment, for example &lt;code&gt;https://yourorg.api.crm4.dynamics.com&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;The &lt;code&gt;Client ID&lt;/code&gt; and &lt;code&gt;Client Secret&lt;/code&gt; from the Azure Active Directory (EntraID) App used to access Dataverse. See the &lt;a href="https://learn.microsoft.com/en-us/power-apps/developer/data-platform/walkthrough-register-app-azure-active-directory" target="_blank"&gt;Microsoft Webpage here&lt;/a&gt; for more information on how to create this app.&lt;/li&gt;
&lt;/ol&gt;
&lt;p&gt;The final connection string should look like the following:&lt;/p&gt;
&lt;p&gt;&lt;code&gt;AuthType=ClientSecret;url=https://yourorg.api.crm4.dynamics.com;ClientId=[CLIENT_ID];ClientSecret=[CLIENT_SECRET]&lt;/code&gt;&lt;/p&gt;
&lt;p&gt;You can find more examples of connection strings for different authentication types in the &lt;a href="https://learn.microsoft.com/en-us/power-apps/developer/data-platform/xrm-tooling/use-connection-strings-xrm-tooling-connect"&gt;Microsoft Dataverse documentation&lt;/a&gt;.&lt;/p&gt;
&lt;h3 id="sql-database-connection-string"&gt;2. SQL Database Connection String&lt;/h3&gt;
&lt;p&gt;For the SQL Database Connection String you will need:&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;The server name enterd as &lt;code&gt;data source&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;Database name entered as &lt;code&gt;initial catalog&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;&lt;code&gt;Integrated Security=true;encrypt=True;trustservercertificate=True&lt;/code&gt;&lt;/li&gt;
&lt;/ol&gt;
&lt;p&gt;To get your SQL Server database connection string details open SQL Server Management Studio and go to database properties -&amp;gt; Connection details. Alternatively speak to your DBA who will be able to get it for you.&lt;/p&gt;
&lt;p&gt;This should look something like the following:&lt;/p&gt;
&lt;p&gt;&lt;code&gt;data source=.\SQLEXPRESS;initial catalog=MirraSqlDb;Integrated Security=true;encrypt=True;trustservercertificate=True&lt;/code&gt;&lt;/p&gt;
&lt;p&gt;The above example is where the server is a local SQL Express instance and the database &amp;quot;MirraSqlDb&amp;quot;.&lt;/p&gt;
&lt;h2 id="set-the-connections"&gt;Set the Connections&lt;/h2&gt;
&lt;p&gt;Once you have both connection strings, set them in MirraSQL with these two commands:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;MirraSQL config set source=&amp;quot;AuthType=ClientSecret;url=https://yourorg.api.crm4.dynamics.com;ClientId=[CLIENT_ID];ClientSecret=[CLIENT_SECRET]&amp;quot;
MirraSQL config set target=&amp;quot;data source=.\SQLEXPRESS;initial catalog=MirraSqlDb;Integrated Security=true;encrypt=True;trustservercertificate=True&amp;quot;
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;To confirm your settings were saved correctly:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;MirraSQL config show
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;This will present the source and target connection strings with the Client Secret being hidden.&lt;/p&gt;
&lt;p&gt;That's all the configuration you need to get started.&lt;/p&gt;
&lt;h2 id="your-first-import"&gt;Your First Import&lt;/h2&gt;
&lt;p&gt;With your connections set up, importing entities is a single command. Pass the logical names of the Dataverse entities you want to import:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;MirraSQL import account contact systemuser
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;MirraSQL will connect to both systems, create the SQL tables if they don't exist, and import the records.&lt;/p&gt;
&lt;p&gt;The codeblock below shows the output for the first time sync of the account, contact and systemuser entities. MirraSQL will fetch the schema, create the tables, and then import the records to these tables:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;MirraSql Version 1.0.0 - Demo Mode (Expires 10/05/2026)
Copyright 2026 Simego Ltd

Using profile: [default]

√ Connected to Dataverse
√ Connected to SQL Server

Importing 3 entities...

[1/3] [account] 186 inserted, 0 updated, 0 deleted (4.6s)
[2/3] [contact] 570 inserted, 0 updated, 0 deleted (3.14s)
[3/3] [systemuser] 202 inserted, 0 updated, 0 deleted (2.13s)

√ Import complete
√ 3 entities, total records 958 inserted, 0 updated, 0 deleted
√ Total time: 9.87 seconds
&lt;/code&gt;&lt;/pre&gt;
&lt;blockquote&gt;
&lt;p&gt;Note: Deletes are hard deletes as it is replicating the Dataverse environment into your Database.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;You can pass as many entity names as you need in a single command:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;MirraSQL import account contact lead opportunity product systemuser team
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;Each entity is then processed in sequence with its own record count and timing, and a summary is shown at the end.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;MirraSql Version 1.0.0 - Demo Mode (Expires 10/05/2026)
Copyright 2026 Simego Ltd

Using profile: [default]

√ Connected to Dataverse
√ Connected to SQL Server

Importing 7 entities...

[1/7] [account] 0 inserted, 3 updated, 0 deleted (3.91s)
[2/7] [contact] 1 inserted, 4 updated, 0 deleted (2.5s)
[3/7] [lead] 0 inserted, 0 updated, 0 deleted (0.29s)
[4/7] [opportunity] 2 inserted, 0 updated, 0 deleted (2.57s)
[5/7] [product] 1 inserted, 0 updated, 0 deleted (1.18s)
[6/7] [systemuser] 0 inserted, 0 updated, 0 deleted (1.28s)
[7/7] [team] 41 inserted, 0 updated, 0 deleted (2.53s)

√ Import complete
√ 7 entities, total records 45 inserted, 7 updated, 0 deleted
√ Total time: 14.26 seconds
&lt;/code&gt;&lt;/pre&gt;
&lt;h2 id="incremental-imports"&gt;Incremental Imports&lt;/h2&gt;
&lt;p&gt;Once your tables are populated from a full import, you can switch to incremental mode to pull only new and modified records by keeping track of the 'versionnumber' in the MirraSql metadata table rather than reloading everything. Use &lt;code&gt;--incremental&lt;/code&gt; or &lt;code&gt;-i&lt;/code&gt;:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;MirraSQL import account contact systemuser --incremental
&lt;/code&gt;&lt;/pre&gt;
&lt;pre&gt;&lt;code&gt;MirraSql Version 1.0.0 - Demo Mode (Expires 10/05/2026)
Copyright 2026 Simego Ltd

Using profile: [default]

√ Connected to Dataverse
√ Connected to SQL Server

Importing 3 entities...

[1/3] [account] 0 inserted, 0 updated, 0 deleted (1.74s)
[2/3] [contact] 0 inserted, 0 updated, 0 deleted (0.2s)
[3/3] [systemuser] 0 inserted, 0 updated, 0 deleted (0.2s)

√ Import complete
√ 3 entities, total records 0 inserted, 0 updated, 0 deleted
√ Total time: 2.15 seconds
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;Incremental mode is particularly useful when you want to minimise the time and load of each run. The typical pattern is to run a full import first to populate your tables, then use &lt;code&gt;--incremental&lt;/code&gt; for all subsequent runs.&lt;/p&gt;
&lt;p&gt;To extend the functionality you can combine it with a profile and log file:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;MirraSQL import account contact lead opportunity --incremental --profile prod --log-file &amp;quot;C:\Logs\mirrasql_log&amp;quot;
&lt;/code&gt;&lt;/pre&gt;
&lt;blockquote&gt;
&lt;p&gt;Note the log file will be overwritten if the command is run again writing to the same output.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;h2 id="setting-up-profiles"&gt;Setting Up Profiles&lt;/h2&gt;
&lt;p&gt;Once you're comfortable with the basics, profiles let you store multiple named connection configurations. This is useful when you're working across different environments such as development, UAT, and production.&lt;/p&gt;
&lt;p&gt;Create a named profile by adding &lt;code&gt;--profile [PROFILENAME]&lt;/code&gt; to the config set commands. For example:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;MirraSQL config set source=&amp;quot;AuthType=ClientSecret;url=https://yourorg.api.crm4.dynamics.com;ClientId=[CLIENT_ID];ClientSecret=[CLIENT_SECRET]&amp;quot; --profile dev
MirraSQL config set target=&amp;quot;Server=DEVSQL;Database=MirraSqlDb;Integrated Security=true&amp;quot; --profile dev
&lt;/code&gt;&lt;/pre&gt;
&lt;pre&gt;&lt;code&gt;MirraSQL config set source=&amp;quot;AuthType=ClientSecret;url=https://yourorg.api.crm4.dynamics.com;ClientId=[CLIENT_ID];ClientSecret=[CLIENT_SECRET]&amp;quot; --profile prod
MirraSQL config set target=&amp;quot;Server=PRODSQL;Database=MirraSqlDb;Integrated Security=true&amp;quot; --profile prod
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;To check what's stored in a profile:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;MirraSQL config show --profile prod
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;To see all configured profiles:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;MirraSQL config list
&lt;/code&gt;&lt;/pre&gt;
&lt;h3 id="switching-profiles"&gt;Switching Profiles&lt;/h3&gt;
&lt;p&gt;You can then use &lt;code&gt;--profile&lt;/code&gt; or &lt;code&gt;-p&lt;/code&gt; on any import command to target that environment:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;MirraSQL import account contact --profile dev
&lt;/code&gt;&lt;/pre&gt;
&lt;pre&gt;&lt;code&gt;MirraSQL import account contact --profile prod
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;This makes it easy to test imports against a development database before running against production.&lt;/p&gt;
&lt;h2 id="additional-features"&gt;Additional Features&lt;/h2&gt;
&lt;h3 id="targeting-a-specific-sql-schema"&gt;Targeting a Specific SQL Schema&lt;/h3&gt;
&lt;p&gt;By default MirraSQL creates tables in the &lt;code&gt;dbo&lt;/code&gt; schema. Use &lt;code&gt;--schema&lt;/code&gt; to target a different one:&lt;/p&gt;
&lt;div class="lang-cmd editor-colors"&gt;MirraSQL import account contact systemuser --schema crm
&lt;/div&gt;
&lt;p&gt;This creates tables as &lt;code&gt;crm.account&lt;/code&gt;, &lt;code&gt;crm.contact&lt;/code&gt;, and &lt;code&gt;crm.systemuser&lt;/code&gt;. Useful if you want to keep your Dataverse data isolated from other tables in the same database.&lt;/p&gt;
&lt;h3 id="controlling-page-size"&gt;Controlling Page Size&lt;/h3&gt;
&lt;p&gt;By default MirraSQL fetches records from Dataverse in pages of 5,000. For very large entities you may want to reduce this:&lt;/p&gt;
&lt;div class="lang-cmd editor-colors"&gt;MirraSQL import account --source-page-size 1000
&lt;/div&gt;
&lt;p&gt;Reducing the page size can help with entities with large string data like attachments and files.&lt;/p&gt;
&lt;h3 id="skipping-schema-synchronisation"&gt;Skipping Schema Synchronisation&lt;/h3&gt;
&lt;p&gt;If your SQL tables already exist and you don't want MirraSQL to check or modify the schema, use &lt;code&gt;--skip-schema-sync&lt;/code&gt;:&lt;/p&gt;
&lt;div class="lang-cmd editor-colors"&gt;MirraSQL import account contact --skip-schema-sync
&lt;/div&gt;
&lt;p&gt;This can speed up repeated imports once your tables are set up correctly.&lt;/p&gt;
&lt;h2 id="quick-reference"&gt;Quick Reference&lt;/h2&gt;
&lt;pre&gt;&lt;code&gt;Arguments:
  &amp;lt;entities&amp;gt;   One or more Dataverse entity logical names to import (required)

Options:
  -s, --schema &amp;lt;schema&amp;gt;           Database schema [default: dbo]
  --skip-schema-sync              Skip schema synchronisation
  -i, --incremental               Incremental mode — only import new and modified records
  --source-page-size &amp;lt;number&amp;gt;     Records per Dataverse API page [default: 5000]
  -p, --profile &amp;lt;profile&amp;gt;         Configuration profile [default: default]
  -l, --log-file &amp;lt;path&amp;gt;           Path to write log output
  -?, -h, --help                  Show help and usage
  --version                       Show version information
&lt;/code&gt;&lt;/pre&gt;
&lt;h2 id="mirrasql-and-data-sync-complementary-tools"&gt;MirraSQL and Data Sync — Complementary Tools&lt;/h2&gt;
&lt;p&gt;MirraSQL and Data Synchronisation Studio serve different purposes and work well alongside each other.&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Use &lt;strong&gt;MirraSQL&lt;/strong&gt; for Dataverse -&amp;gt; SQL imports for reporting, backup, or analytics. It is optimised for bulk entity imports.&lt;/li&gt;
&lt;li&gt;Use &lt;strong&gt;Data Sync&lt;/strong&gt; when you need complex field mappings, transformations, or integration between any combination of systems.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;A common pattern is to use MirraSQL for nightly full Dataverse imports into a reporting database, while Data Sync handles specific integrations that require custom logic.&lt;/p&gt;
&lt;h2 id="try-it-out"&gt;Try It Out&lt;/h2&gt;
&lt;p&gt;MirraSQL is currently in beta, but you can &lt;a href="https://www.simego.com/products/mirrasql"&gt;download it here&lt;/a&gt; and give it a try against your own Dataverse environment. We're actively collecting feedback on which features matter most, so your input can directly shape what gets built next.&lt;/p&gt;
&lt;p&gt;If you have questions or run into anything unexpected, get in touch at &lt;a href="mailto:support@simego.com"&gt;support@simego.com&lt;/a&gt;.&lt;/p&gt;
</description>
      <source url="http://www.simego.com/blog">Team Blog</source>
      <pubDate>Fri, 27 Feb 2026 12:39:33 +0000</pubDate>
    </item>
  </channel>
</rss>