<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>office 365 Archives | ZappySys Blog</title>
	<atom:link href="https://zappysys.com/blog/tag/office-365/feed/" rel="self" type="application/rss+xml" />
	<link>https://zappysys.com/blog/tag/office-365/</link>
	<description>SSIS / ODBC Drivers / API Connectors for JSON, XML, Azure, Amazon AWS, Salesforce, MongoDB and more</description>
	<lastBuildDate>Thu, 05 Mar 2026 01:25:16 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	<generator>https://wordpress.org/?v=6.4.4</generator>

<image>
	<url>https://zappysys.com/blog/wp-content/uploads/2023/01/cropped-zappysys-symbol-large-32x32.png</url>
	<title>office 365 Archives | ZappySys Blog</title>
	<link>https://zappysys.com/blog/tag/office-365/</link>
	<width>32</width>
	<height>32</height>
</image> 
	<item>
		<title>How to Get Office 365 Mail Attachments using SSIS</title>
		<link>https://zappysys.com/blog/get-office-365-mail-attachments-using-ssis/</link>
		
		<dc:creator><![CDATA[ZappySys]]></dc:creator>
		<pubDate>Sat, 22 Feb 2020 08:27:34 +0000</pubDate>
				<category><![CDATA[REST API]]></category>
		<category><![CDATA[SSIS JSON Parser Transform]]></category>
		<category><![CDATA[SSIS JSON Source (File/REST)]]></category>
		<category><![CDATA[SSIS OAuth Connection]]></category>
		<category><![CDATA[SSIS PowerPack]]></category>
		<category><![CDATA[SSIS Template Transform]]></category>
		<category><![CDATA[SSIS Trash Destination]]></category>
		<category><![CDATA[SSIS WEB API Destination]]></category>
		<category><![CDATA[attachments]]></category>
		<category><![CDATA[json]]></category>
		<category><![CDATA[office 365]]></category>
		<category><![CDATA[outlook]]></category>
		<category><![CDATA[ssis]]></category>
		<guid isPermaLink="false">https://zappysys.com/blog/?p=8791</guid>

					<description><![CDATA[<p>Introduction In our previous article, we saw how to get Office 365 data in Power BI. Now, let’s look at how to get Office 365 Mail Attachments using SSIS without any coding. Microsoft Graph API is a unified way to access many Microsoft services, including the Office 365 API. In this post, we will use the SSIS [&#8230;]</p>
<p>The post <a href="https://zappysys.com/blog/get-office-365-mail-attachments-using-ssis/">How to Get Office 365 Mail Attachments using SSIS</a> appeared first on <a href="https://zappysys.com/blog">ZappySys Blog</a>.</p>
]]></description>
										<content:encoded><![CDATA[<h2>Introduction</h2>
<div class="su-note"  style="border-color:#e5dd9d;border-radius:3px;-moz-border-radius:3px;-webkit-border-radius:3px;"><div class="su-note-inner su-u-clearfix su-u-trim" style="background-color:#fff7b7;border-color:#ffffff;color:#333333;border-radius:3px;-moz-border-radius:3px;-webkit-border-radius:3px;"><strong>UPDATE:</strong> ZappySys has released a brand new <a href="https://zappysys.com/api/integration-hub/outlook-mail-connector/ssis">Outlook Mail (Office 365) connector</a>, which makes it much simpler to <strong>download attachments, read/search emails, users, mail folders, send email, and more in SSIS</strong> compared to the steps listed in this article. You can still use the steps from this article, but if you are new to APIs or want to avoid the learning curve, use a newer approach.</div></div>
<p><a href="//zappysys.com/blog/wp-content/uploads/2017/08/microsoft-office-365-api-integration.png"><img decoding="async" class="alignleft wp-image-1694" src="//zappysys.com/blog/wp-content/uploads/2017/08/microsoft-office-365-api-integration.png" alt="" width="100" height="100" srcset="https://zappysys.com/blog/wp-content/uploads/2017/08/microsoft-office-365-api-integration.png 241w, https://zappysys.com/blog/wp-content/uploads/2017/08/microsoft-office-365-api-integration-150x150.png 150w" sizes="(max-width: 100px) 100vw, 100px" /></a><span style="box-sizing: border-box; margin: 0px; padding: 0px;">In our previous article, we saw <a href="https://zappysys.com/blog/get-office-365-data-in-power-bi-using-microsoft-graph-api-and-odbc/" target="_blank" rel="noopener">how to get Office 365 data in Power BI</a>.</span> Now, let’s look at how to get Office 365 Mail Attachments using SSIS without any coding. <a href="https://developer.microsoft.com/en-us/graph/docs/concepts/overview" target="_blank" rel="noopener">Microsoft Graph API</a> is a unified way to access many Microsoft services, including the <strong>Office 365 API</strong>. In this post, we will use the <a href="//zappysys.com/products/ssis-powerpack/ssis-json-file-source/" target="_blank" rel="noopener">SSIS JSON</a><span style="box-sizing: border-box; margin: 0px; padding: 0px;"><a target="_blank" rel="noopener">/REST API Source Connector</a> to retrieve the Outlook Messages list and its attachments</span>.</p>
<h2></h2>
<div class="content_block" id="custom_post_widget-2523"><h2><span id="Prerequisites">Prerequisites</span></h2>
Before we perform the steps listed in this article, you will need to make sure the following prerequisites are met:
<ol style="margin-left: 1.5em;">
 	<li><abbr title="SQL Server Integration Services">SSIS</abbr> designer installed. Sometimes it is referred to as <abbr title="Business Intelligence Development Studio">BIDS</abbr> or <abbr title="SQL Server Data Tools">SSDT</abbr> (<a href="https://docs.microsoft.com/en-us/sql/ssdt/download-sql-server-data-tools-ssdt" target="_blank" rel="noopener">download it from the Microsoft site</a>).</li>
 	<li>Basic knowledge of SSIS package development using <em>Microsoft SQL Server Integration Services</em>.</li>
 	<li>Make sure <span style="text-decoration: underline;"><a href="https://zappysys.com/products/ssis-powerpack/" target="_blank" rel="noopener">ZappySys SSIS PowerPack</a></span> is installed (<a href="https://zappysys.com/products/ssis-powerpack/download/" target="_blank" rel="noopener">download it</a>, if you haven't already).</li>
 	<li>(<em>Optional step</em>)<em>.</em> <a href="https://zappysys.zendesk.com/hc/en-us/articles/360035974593" target="_blank" rel="noopener">Read this article</a>, if you are planning to deploy packages to a server and schedule their execution later.</li>
</ol></div>
<h2>Use Case of Microsoft Graph API</h2>
<p>Here are some use cases for why you want to use the Microsoft Graph API</p>
<ul>
<li>Read/Write events from <strong>Outlook Calendar</strong></li>
<li>Send <strong>email</strong>  / Read <strong>emails</strong></li>
<li>Get the list of files from <strong>OneDrive</strong></li>
<li>Upload/ Download files to <strong>OneDrive</strong></li>
<li>Read/Write <strong>Excel Sheet</strong> (Use range or a specific range of a specific sheet)</li>
<li>Read <b>the SharePoint</b> Document library</li>
<li>Search content from <b>the SharePoint</b> document library</li>
<li>Get AD users for your Organization (AD Accounts)</li>
<li>Update OneNote</li>
<li>Track changes to Users, Events, Calendar Items using the <a href="https://developer.microsoft.com/en-us/graph/docs/concepts/delta_query_overview" target="_blank" rel="noopener">delta API</a></li>
</ul>
<div class="content_block" id="custom_post_widget-5670"><h2 style="text-align: left;">Register Application (OAuth2 App for Graph API)</h2>
<p style="text-align: left;">The first step to access any Office 365 API / Graph API is to register an OAuth App in the Azure Portal. After
following these steps, you will get the following two items to use in the next section:</p>

<ul style="text-align: left;">
 	<li>Application Id</li>
 	<li>Application Secret</li>
</ul>
<p style="text-align: left;">In this section, you will learn how to register a custom app in Microsoft Azure portal that will allow access to the
OneDrive. So, let's get started -</p>

<ol>
 	<li style="text-align: left;">Log into <a href="https://portal.azure.com/#blade/Microsoft_AAD_IAM/ActiveDirectoryMenuBlade/RegisteredApps">Microsoft
Azure portal</a> to register a custom app.</li>
 	<li style="text-align: left;">Register a new application by clicking New Registration link.<a href="https://zappysys.com/blog/wp-content/uploads/2020/07/NewRegistration.png"><img fetchpriority="high" decoding="async" class="size-full wp-image-9034" src="https://zappysys.com/blog/wp-content/uploads/2020/07/NewRegistration.png" alt="New App Registration in Azure portal" width="748" height="221" srcset="https://zappysys.com/blog/wp-content/uploads/2020/07/NewRegistration.png 748w, https://zappysys.com/blog/wp-content/uploads/2020/07/NewRegistration-300x89.png 300w" sizes="(max-width: 748px) 100vw, 748px" /></a></li>
 	<li style="text-align: left;">Provide the name of the custom app and who can access the app in the organization.<a href="https://zappysys.com/blog/wp-content/uploads/2020/07/RegisterOneDriveApp-1.jpg"><img loading="lazy" decoding="async" class="wp-image-9005 size-full" src="https://zappysys.com/blog/wp-content/uploads/2020/07/RegisterOneDriveApp-1.jpg" alt="Register an OneDrive App" width="610" height="518" srcset="https://zappysys.com/blog/wp-content/uploads/2020/07/RegisterOneDriveApp-1.jpg 610w, https://zappysys.com/blog/wp-content/uploads/2020/07/RegisterOneDriveApp-1-300x255.jpg 300w" sizes="(max-width: 610px) 100vw, 610px" /></a></li>
 	<li style="text-align: left;">Go to the App overview and add a Redirect URL.<a href="https://zappysys.com/blog/wp-content/uploads/2020/07/RedirectURI-1.jpg"><img loading="lazy" decoding="async" class="wp-image-9044 size-full" src="https://zappysys.com/blog/wp-content/uploads/2020/07/RedirectURI-1.jpg" alt="Add a Redirect URL" width="937" height="122" srcset="https://zappysys.com/blog/wp-content/uploads/2020/07/RedirectURI-1.jpg 937w, https://zappysys.com/blog/wp-content/uploads/2020/07/RedirectURI-1-300x39.jpg 300w, https://zappysys.com/blog/wp-content/uploads/2020/07/RedirectURI-1-768x100.jpg 768w" sizes="(max-width: 937px) 100vw, 937px" /></a></li>
 	<li style="text-align: left;">Click on "Add a Platform" under Platform Configuration section and then select "Web" under Web applications
section to enter a Redirect URL.
<pre class="lang:default decode:true">https://zappysys.com/oauth</pre>
<a href="https://zappysys.com/blog/wp-content/uploads/2020/07/RedirectURI2.jpg"><img loading="lazy" decoding="async" class="size-full wp-image-9007" src="https://zappysys.com/blog/wp-content/uploads/2020/07/RedirectURI2.jpg" alt="Redirect URL" width="466" height="564" srcset="https://zappysys.com/blog/wp-content/uploads/2020/07/RedirectURI2.jpg 466w, https://zappysys.com/blog/wp-content/uploads/2020/07/RedirectURI2-248x300.jpg 248w" sizes="(max-width: 466px) 100vw, 466px" /></a></li>
 	<li style="text-align: left;">Create a Client Secret key which will be used to Authenticate the custom Azure app.<a href="https://zappysys.com/blog/wp-content/uploads/2020/07/ClientSecret.jpg"><img loading="lazy" decoding="async" class="size-full wp-image-9010" src="https://zappysys.com/blog/wp-content/uploads/2020/07/ClientSecret.jpg" alt="Add a Client Secret" width="576" height="403" srcset="https://zappysys.com/blog/wp-content/uploads/2020/07/ClientSecret.jpg 576w, https://zappysys.com/blog/wp-content/uploads/2020/07/ClientSecret-300x210.jpg 300w" sizes="(max-width: 576px) 100vw, 576px" /></a><a href="https://zappysys.com/blog/wp-content/uploads/2020/07/ClientSecret2.jpg"><img loading="lazy" decoding="async" class="size-full wp-image-9011" src="https://zappysys.com/blog/wp-content/uploads/2020/07/ClientSecret2.jpg" alt="Secret Key Expiration Period" width="208" height="259" /></a><a href="https://zappysys.com/blog/wp-content/uploads/2020/07/ClientSecret3.jpg"><img loading="lazy" decoding="async" class="size-full wp-image-9012" src="https://zappysys.com/blog/wp-content/uploads/2020/07/ClientSecret3.jpg" alt="Specify Secret Key" width="1024" height="176" srcset="https://zappysys.com/blog/wp-content/uploads/2020/07/ClientSecret3.jpg 1024w, https://zappysys.com/blog/wp-content/uploads/2020/07/ClientSecret3-300x52.jpg 300w, https://zappysys.com/blog/wp-content/uploads/2020/07/ClientSecret3-768x132.jpg 768w" sizes="(max-width: 1024px) 100vw, 1024px" /></a>
<div><strong>Note</strong> - Take a note of <strong>Client Secret</strong>, it will be required while
configuring OAuth connection in the SSIS later</div></li>
 	<li style="text-align: left;">Add API Permissions.<a href="https://zappysys.com/blog/wp-content/uploads/2020/07/APIPermissions.jpg"><img loading="lazy" decoding="async" class="size-full wp-image-9008" src="https://zappysys.com/blog/wp-content/uploads/2020/07/APIPermissions.jpg" alt="OneDrive API Permissions" width="1291" height="415" /></a></li>
 	<li style="text-align: left;">Select following permissions from the Delegated Permissions section.
<pre class="lang:default decode:true">User.ReadBasic.All
Files.Read
offline_access</pre>
<a href="https://zappysys.com/blog/wp-content/uploads/2020/07/APIPermissions2.jpg"><img loading="lazy" decoding="async" class="size-full wp-image-9009" src="https://zappysys.com/blog/wp-content/uploads/2020/07/APIPermissions2.jpg" alt="Select Delegated Permissions" width="512" height="571" srcset="https://zappysys.com/blog/wp-content/uploads/2020/07/APIPermissions2.jpg 512w, https://zappysys.com/blog/wp-content/uploads/2020/07/APIPermissions2-269x300.jpg 269w" sizes="(max-width: 512px) 100vw, 512px" /></a></li>
 	<li>Take a note of Client ID, it will be required while configuring OAuth connection in the SSIS later.<a href="https://zappysys.com/blog/wp-content/uploads/2020/07/ClientSecret4.jpg"><img loading="lazy" decoding="async" class="wp-image-9013 size-full alignleft" src="https://zappysys.com/blog/wp-content/uploads/2020/07/ClientSecret4.jpg" alt="App Client ID" width="810" height="274" /></a></li>
</ol></div>
<h2>Step-By-Step to call the Microsoft Graph Rest API Using SSIS</h2>
<p>Now, let&#8217;s look at examples to access your Outlook.com emails using SSIS. You can use the same techniques to call pretty much any Office 365 API.</p>
<h3>Configure SSIS OAuth Connection for Graph REST API</h3>
<p>The first step to access any Graph API is to configure an OAuth connection</p>
<ol>
<li>Open Visual Studio</li>
<li>Open an existing SSIS Project or create a new one using File &gt; New &gt; Project &gt; Choose “Integration Services Project” Type under Business Intelligence template category.</li>
<li>Create Package</li>
<li>Right-click inside the Connection Managers area and click <strong>New Connection…</strong></li>
<li>From the connection type list, select the <strong>ZS-OAUTH</strong> connection type.
<div id="attachment_11825" style="width: 959px" class="wp-caption alignnone"><a href="https://zappysys.com/blog/wp-content/uploads/2020/02/Create-a-new-SSIS-OAuth-API-Connection-Manager.png"><img loading="lazy" decoding="async" aria-describedby="caption-attachment-11825" class="size-full wp-image-11825" src="https://zappysys.com/blog/wp-content/uploads/2020/02/Create-a-new-SSIS-OAuth-API-Connection-Manager.png" alt="" width="949" height="447" srcset="https://zappysys.com/blog/wp-content/uploads/2020/02/Create-a-new-SSIS-OAuth-API-Connection-Manager.png 949w, https://zappysys.com/blog/wp-content/uploads/2020/02/Create-a-new-SSIS-OAuth-API-Connection-Manager-300x141.png 300w, https://zappysys.com/blog/wp-content/uploads/2020/02/Create-a-new-SSIS-OAuth-API-Connection-Manager-768x362.png 768w" sizes="(max-width: 949px) 100vw, 949px" /></a><p id="caption-attachment-11825" class="wp-caption-text">Create a new SSIS OAuth API Connection Manager</p></div></li>
<li>On the OAuth Connection Manager, configure the following options
<ol style="list-style-type: lower-alpha;">
<li>Select &#8220;Custom&#8221; from the Provider dropdown</li>
<li>Select OAuth2 from the OAuth version</li>
<li>Enter your Application Id and Secret Key (i.e., App Password) obtained in the previous section <a href="https://apps.dev.microsoft.com/#/appList" target="_blank" rel="noopener">from here</a>.</li>
<li>Enter the following URL in the Authorization URL<br />
<pre class="crayon-plain-tag">https://login.microsoftonline.com/common/oauth2/v2.0/authorize</pre>
</li>
<li>Use the following URL in the token URL field<br />
<pre class="crayon-plain-tag">https://login.microsoftonline.com/common/oauth2/v2.0/token</pre>
</li>
<li>Enter the following <a href="https://developer.microsoft.com/en-us/graph/docs/authorization/permission_scopes" target="_blank" rel="noopener">Graph API Scopes</a> (each scope must be entered on a new line).<br />
<pre class="crayon-plain-tag">user.read
mail.read
offline_access</pre>
<div class="su-note"  style="border-color:#e5dd9d;border-radius:3px;-moz-border-radius:3px;-webkit-border-radius:3px;"><div class="su-note-inner su-u-clearfix su-u-trim" style="background-color:#fff7b7;border-color:#ffffff;color:#333333;border-radius:3px;-moz-border-radius:3px;-webkit-border-radius:3px;">NOTE: Always include <strong>the offline_access</strong> scope, which returns a refresh_token, which allows you to renew the token without going through the login process again. <span style="box-sizing: border-box; margin: 0px; padding: 0px;">For more information about which scopes are needed, always refer to the API help page (e.g., if you want to read mail using <a href="https://developer.microsoft.com/en-us/graph/docs/api-reference/v1.0/api/user_list_messages" target="_blank" rel="noopener">this API,</a> then you will see it says you can use <strong>Mail.Read</strong> or <strong>Mail.ReadWrite</strong> scope).</span></div></div></li>
<li>Go to the <strong>Advanced tab</strong> and enter the following URL in the Callback/Return URL (assuming the same URL used when you registered the App in the previous section)<br />
<pre class="crayon-plain-tag">https://zappysys.com/oauth</pre>
</li>
<li>Now go back to the first tab and click Generate Token. When prompted, log in using your Personal Microsoft Account or Work Account (Office 365 or AD login)</li>
<li>After logging in, you will see the Accept option. Just click it. If things go right, then you will see the Access Token and Refresh Token fields populated.</li>
</ol>
</li>
<li>Once everything is configured, you can click <strong>Test Connection</strong> to verify the connection works.
<div class="mceTemp"></div>
<div id="attachment_11832" style="width: 713px" class="wp-caption alignnone"><a href="https://zappysys.com/blog/wp-content/uploads/2020/02/SSIS-OAuth-Connection-Manager-for-Office-365-REST-API-Microsoft-Graph-API.png"><img loading="lazy" decoding="async" aria-describedby="caption-attachment-11832" class="size-full wp-image-11832" src="https://zappysys.com/blog/wp-content/uploads/2020/02/SSIS-OAuth-Connection-Manager-for-Office-365-REST-API-Microsoft-Graph-API.png" alt="" width="703" height="754" srcset="https://zappysys.com/blog/wp-content/uploads/2020/02/SSIS-OAuth-Connection-Manager-for-Office-365-REST-API-Microsoft-Graph-API.png 703w, https://zappysys.com/blog/wp-content/uploads/2020/02/SSIS-OAuth-Connection-Manager-for-Office-365-REST-API-Microsoft-Graph-API-280x300.png 280w" sizes="(max-width: 703px) 100vw, 703px" /></a><p id="caption-attachment-11832" class="wp-caption-text">SSIS OAuth Connection Manager for Office 365 REST API Microsoft Graph API</p></div></li>
</ol>
<div class="su-note"  style="border-color:#e5de9d;border-radius:3px;-moz-border-radius:3px;-webkit-border-radius:3px;"><div class="su-note-inner su-u-clearfix su-u-trim" style="background-color:#fff8b7;border-color:#ffffff;color:#333333;border-radius:3px;-moz-border-radius:3px;-webkit-border-radius:3px;">NOTE: Typically, RefreshToken is long-lived, but in some cases, they may expire soon too. If that’s the case, then you can configure the above OAuth connection to change the refresh token pattern. Simply enter the token file path and re-authenticate by clicking Generate Token. After that, each time you make an API call, it will save a new refresh token in the file.</div></div>
<h3>Download the Messages Attachment Files from Outlook</h3>
<p>Let’s start with an example. We use the SSIS JSON Source and Web API Destination components to make a call to the Microsoft Graph REST API.</p>
<ol>
<li>First of all, drag and drop the <strong>Data Flow Task</strong> from the SSIS Toolbox and double-click it to edit.
<div id="attachment_11784" style="width: 485px" class="wp-caption alignnone"><a href="https://zappysys.com/blog/wp-content/uploads/2026/02/Drag-and-drop-Data-flow.png"><img loading="lazy" decoding="async" aria-describedby="caption-attachment-11784" class="size-full wp-image-11784" src="https://zappysys.com/blog/wp-content/uploads/2026/02/Drag-and-drop-Data-flow.png" alt="" width="475" height="178" srcset="https://zappysys.com/blog/wp-content/uploads/2026/02/Drag-and-drop-Data-flow.png 475w, https://zappysys.com/blog/wp-content/uploads/2026/02/Drag-and-drop-Data-flow-300x112.png 300w" sizes="(max-width: 475px) 100vw, 475px" /></a><p id="caption-attachment-11784" class="wp-caption-text">Drag and drop Data flow</p></div></li>
<li>From the SSIS toolbox, drag and drop the<strong> JSON Source</strong> onto the Data Flow Designer surface.
<div class="mceTemp"></div>
<div id="attachment_11533" style="width: 553px" class="wp-caption alignnone"><a href="https://zappysys.com/blog/wp-content/uploads/2015/09/ssis-json-source-adapter-drag.png"><img loading="lazy" decoding="async" aria-describedby="caption-attachment-11533" class="size-full wp-image-11533" src="https://zappysys.com/blog/wp-content/uploads/2015/09/ssis-json-source-adapter-drag.png" alt="" width="543" height="146" srcset="https://zappysys.com/blog/wp-content/uploads/2015/09/ssis-json-source-adapter-drag.png 543w, https://zappysys.com/blog/wp-content/uploads/2015/09/ssis-json-source-adapter-drag-300x81.png 300w" sizes="(max-width: 543px) 100vw, 543px" /></a><p id="caption-attachment-11533" class="wp-caption-text">SSIS JSON Source &#8211; Drag and Drop</p></div></li>
<li>Double-click the <a href="https://zappysys.com/products/ssis-powerpack/ssis-json-file-source/?"><strong>JSON Source</strong></a>, then enter the following URL to invoke the Messages API call with search options to retrieve emails with attachments.<br />
<pre class="crayon-plain-tag">https://graph.microsoft.com/v1.0/me/messages?$select=sentDateTime,from,subject,hasAttachments&amp;$search="hasAttachments:True"</pre>
Set the filter to <code>$.value[*]</code> and click the preview.</p>
<div id="attachment_11831" style="width: 837px" class="wp-caption alignnone"><a href="https://zappysys.com/blog/wp-content/uploads/2020/02/SSIS-JSON-Source-–-Get-data-from-Microsoft-Graph-API-Office-365-API-–-Read-Mail-Example.png"><img loading="lazy" decoding="async" aria-describedby="caption-attachment-11831" class="size-full wp-image-11831" src="https://zappysys.com/blog/wp-content/uploads/2020/02/SSIS-JSON-Source-–-Get-data-from-Microsoft-Graph-API-Office-365-API-–-Read-Mail-Example.png" alt="" width="827" height="887" srcset="https://zappysys.com/blog/wp-content/uploads/2020/02/SSIS-JSON-Source-–-Get-data-from-Microsoft-Graph-API-Office-365-API-–-Read-Mail-Example.png 827w, https://zappysys.com/blog/wp-content/uploads/2020/02/SSIS-JSON-Source-–-Get-data-from-Microsoft-Graph-API-Office-365-API-–-Read-Mail-Example-280x300.png 280w, https://zappysys.com/blog/wp-content/uploads/2020/02/SSIS-JSON-Source-–-Get-data-from-Microsoft-Graph-API-Office-365-API-–-Read-Mail-Example-768x824.png 768w" sizes="(max-width: 827px) 100vw, 827px" /></a><p id="caption-attachment-11831" class="wp-caption-text">SSIS JSON Source – Get data from Microsoft Graph API (Office 365 API – Read Mail Example)</p></div>
<p>To customize the URL with additional parameters, check <a href="https://developer.microsoft.com/en-us/graph/docs/overview/query_parameters" target="_blank" rel="noopener">this help link</a>. It’s a standard OData Protocol, so you can leverage many common OData features (e.g., use $top parameters to set pageSize. Default is 10 for List Mail, but you can include more records per response by changing it, such as <strong>…/messages?$top=50</strong>).</li>
<li> Now, let&#8217;s use Template Transform to set the URL using the message ID to make the <a href="https://docs.microsoft.com/en-us/graph/api/attachment-get?view=graph-rest-1.0&amp;tabs=http" target="_blank" rel="noopener">Get attachment API</a> call.</p><pre class="crayon-plain-tag">https://graph.microsoft.com/v1.0/me/messages/&lt;%id%&gt;/attachments</pre><p>
<div id="attachment_11833" style="width: 848px" class="wp-caption alignnone"><a href="https://zappysys.com/blog/wp-content/uploads/2020/02/SSIS-Template-Transform-sending-attachment-id.png"><img loading="lazy" decoding="async" aria-describedby="caption-attachment-11833" class="size-full wp-image-11833" src="https://zappysys.com/blog/wp-content/uploads/2020/02/SSIS-Template-Transform-sending-attachment-id.png" alt="" width="838" height="560" srcset="https://zappysys.com/blog/wp-content/uploads/2020/02/SSIS-Template-Transform-sending-attachment-id.png 838w, https://zappysys.com/blog/wp-content/uploads/2020/02/SSIS-Template-Transform-sending-attachment-id-300x200.png 300w, https://zappysys.com/blog/wp-content/uploads/2020/02/SSIS-Template-Transform-sending-attachment-id-768x513.png 768w, https://zappysys.com/blog/wp-content/uploads/2020/02/SSIS-Template-Transform-sending-attachment-id-272x182.png 272w" sizes="(max-width: 838px) 100vw, 838px" /></a><p id="caption-attachment-11833" class="wp-caption-text">SSIS Template Transform sending attachment id</p></div>
<div class="mceTemp"></div>
</li>
<li>Now we need to use the <a href="https://zappysys.com/products/ssis-powerpack/ssis-web-api-destination-connector/?_gl=1*1fgshu4*_up*MQ..*_gs*MQ..&amp;gclid=CjwKCAiAzZ_NBhAEEiwAMtqKy8lyVraD40LVoEOcaJPgdN6RaL8j21-KaDKKbrh3VFlYirORdiQ3MxoCtO8QAvD_BwE&amp;gbraid=0AAAAADhWWLJ5j927a8ePIZceRs447LN9W"><strong>Web API Destination</strong></a> to make the Get Attachment API call by message ID. Select the Input column for URL as that TemplateOutput.
<div id="attachment_11834" style="width: 733px" class="wp-caption alignnone"><a href="https://zappysys.com/blog/wp-content/uploads/2020/02/SSIS-Web-API-Destination-–-Get-data-from-Microsoft-Graph-API-Office-365-API-–-Get-Attachment-Example.png"><img loading="lazy" decoding="async" aria-describedby="caption-attachment-11834" class="size-full wp-image-11834" src="https://zappysys.com/blog/wp-content/uploads/2020/02/SSIS-Web-API-Destination-–-Get-data-from-Microsoft-Graph-API-Office-365-API-–-Get-Attachment-Example.png" alt="" width="723" height="775" srcset="https://zappysys.com/blog/wp-content/uploads/2020/02/SSIS-Web-API-Destination-–-Get-data-from-Microsoft-Graph-API-Office-365-API-–-Get-Attachment-Example.png 723w, https://zappysys.com/blog/wp-content/uploads/2020/02/SSIS-Web-API-Destination-–-Get-data-from-Microsoft-Graph-API-Office-365-API-–-Get-Attachment-Example-280x300.png 280w" sizes="(max-width: 723px) 100vw, 723px" /></a><p id="caption-attachment-11834" class="wp-caption-text">SSIS Web API Destination – Get data from Microsoft Graph API (Office 365 API – Get Attachment Example)</p></div></li>
<li>Now, the next step is to parse the JSON Response String of the get attachment api call. For that, we need to use a <strong><a href="https://zappysys.com/products/ssis-powerpack/ssis-json-parser-transform/?utm_source=google&amp;utm_medium=cpc&amp;utm_campaign=22259122063&amp;utm_content=&amp;utm_term=&amp;gad_source=1&amp;gad_campaignid=22582753584&amp;gbraid=0AAAAADhWWLJ5j927a8ePIZceRs447LN9W&amp;gclid=CjwKCAiAzZ_NBhAEEiwAMtqKy1ZTPt9tVn9Xy9xU7z27q__H4RRoMa_SfgZg5L8maavtcr5HfzCl0RoC6_sQAvD_BwE">JSON Parser</a></strong>. Select the input as Web PAI Destination ResponseText and use the below sample JSON string to configure the metadata(Columns).<br />
<pre class="crayon-plain-tag">{"@odata.context":"https://graph.microsoft.com/v1.0/$metadata#users('support%40zappysys.com')/messages('AQMkADAwATMwMAItMDkyMC0zZTg4AC0wMAItMDAKAEYAAAP_JUy')/attachments"
,"value":[{"@odata.type":"#microsoft.graph.fileAttachment","@odata.mediaContentType":"text/plain"
,"id":"AQMkADAwATMwMAItMDkyMC0zZTg4AC0wMAItMDAKAEYAAAP_JUy_27M"
,"lastModifiedDateTime":"2020-02-21T07:36:16Z"
,"name":"Test.txt","contentType":"text/plain","size":870,"isInline":false
,"contentId":null,"contentLocation":null,"contentBytes":"VGVzdCBNZXNzYWdl"}]}</pre>
<div id="attachment_11828" style="width: 1043px" class="wp-caption alignnone"><a href="https://zappysys.com/blog/wp-content/uploads/2020/02/JSON-Parser-Transform-using-JSON-example.png"><img loading="lazy" decoding="async" aria-describedby="caption-attachment-11828" class="size-full wp-image-11828" src="https://zappysys.com/blog/wp-content/uploads/2020/02/JSON-Parser-Transform-using-JSON-example.png" alt="" width="1033" height="713" srcset="https://zappysys.com/blog/wp-content/uploads/2020/02/JSON-Parser-Transform-using-JSON-example.png 1033w, https://zappysys.com/blog/wp-content/uploads/2020/02/JSON-Parser-Transform-using-JSON-example-300x207.png 300w, https://zappysys.com/blog/wp-content/uploads/2020/02/JSON-Parser-Transform-using-JSON-example-1024x707.png 1024w, https://zappysys.com/blog/wp-content/uploads/2020/02/JSON-Parser-Transform-using-JSON-example-768x530.png 768w" sizes="(max-width: 1033px) 100vw, 1033px" /></a><p id="caption-attachment-11828" class="wp-caption-text">JSON Parser Transform &#8211; using JSON example</p></div>
<div class="mceTemp"></div>
</li>
<li> Now, in the JSON Parser, go to the Go-to columns Tab and set the <strong>contentBytes</strong> DataType to <strong>DT_IMAGE,</strong> and increase the other columns&#8217; <strong>DT_WSTR</strong> lengths by 1000 and 1500. We set contentBytes to the <strong>DT_IMAGE</strong>  datatype, which is like varbinary(MAX).
<div id="attachment_11829" style="width: 838px" class="wp-caption alignnone"><a href="https://zappysys.com/blog/wp-content/uploads/2020/02/JSON-Parser-Transform-Columns-Tab-fix-the-datatype.png"><img loading="lazy" decoding="async" aria-describedby="caption-attachment-11829" class="size-full wp-image-11829" src="https://zappysys.com/blog/wp-content/uploads/2020/02/JSON-Parser-Transform-Columns-Tab-fix-the-datatype.png" alt="" width="828" height="611" srcset="https://zappysys.com/blog/wp-content/uploads/2020/02/JSON-Parser-Transform-Columns-Tab-fix-the-datatype.png 828w, https://zappysys.com/blog/wp-content/uploads/2020/02/JSON-Parser-Transform-Columns-Tab-fix-the-datatype-300x221.png 300w, https://zappysys.com/blog/wp-content/uploads/2020/02/JSON-Parser-Transform-Columns-Tab-fix-the-datatype-768x567.png 768w" sizes="(max-width: 828px) 100vw, 828px" /></a><p id="caption-attachment-11829" class="wp-caption-text">JSON Parser Transform Columns Tab fix the datatype</p></div></li>
<li>Furthermore, in the next step, we need to use an SSIS Derived Column to set the FilePath where we want to save the attachments, and then concatenate the local file path with the attachment name column.
<div id="attachment_11830" style="width: 798px" class="wp-caption alignnone"><a href="https://zappysys.com/blog/wp-content/uploads/2020/02/SSIS-Derived-Column-Add-New-Column-1.png"><img loading="lazy" decoding="async" aria-describedby="caption-attachment-11830" class="size-full wp-image-11830" src="https://zappysys.com/blog/wp-content/uploads/2020/02/SSIS-Derived-Column-Add-New-Column-1.png" alt="" width="788" height="624" srcset="https://zappysys.com/blog/wp-content/uploads/2020/02/SSIS-Derived-Column-Add-New-Column-1.png 788w, https://zappysys.com/blog/wp-content/uploads/2020/02/SSIS-Derived-Column-Add-New-Column-1-300x238.png 300w, https://zappysys.com/blog/wp-content/uploads/2020/02/SSIS-Derived-Column-Add-New-Column-1-768x608.png 768w" sizes="(max-width: 788px) 100vw, 788px" /></a><p id="caption-attachment-11830" class="wp-caption-text">SSIS Derived Column: Add New Column</p></div></li>
<li>Finally, we need to use the <a href="https://docs.microsoft.com/en-us/sql/integration-services/data-flow/transformations/export-column-transformation?view=sql-server-ver15" target="_blank" rel="noopener">Export Column</a> Transform (Native) to export attachment bytes to a local file. It needs to know 2 upstream info Bytes and the target file path.
<div id="attachment_11827" style="width: 763px" class="wp-caption alignnone"><a href="https://zappysys.com/blog/wp-content/uploads/2020/02/Export-Column-configuration.png"><img loading="lazy" decoding="async" aria-describedby="caption-attachment-11827" class="size-full wp-image-11827" src="https://zappysys.com/blog/wp-content/uploads/2020/02/Export-Column-configuration.png" alt="" width="753" height="637" srcset="https://zappysys.com/blog/wp-content/uploads/2020/02/Export-Column-configuration.png 753w, https://zappysys.com/blog/wp-content/uploads/2020/02/Export-Column-configuration-300x254.png 300w" sizes="(max-width: 753px) 100vw, 753px" /></a><p id="caption-attachment-11827" class="wp-caption-text">Export Column configuration</p></div></li>
<li>Make sure to attach the export column to some destination (e.g., our ZS Trash Destination); the engine might remove it. At the same time, it optimizes the runtime. It may remove all transformations that don&#8217;t have a destination, such as deploying the package to SQL Server, or when you set optimize in Visual Studio.</li>
<li>That&#8217;s it, execute the package, and it will download all the email attachments.
<div id="attachment_11826" style="width: 1050px" class="wp-caption alignnone"><a href="https://zappysys.com/blog/wp-content/uploads/2020/02/Downloaded-Mail-Attachments.png"><img loading="lazy" decoding="async" aria-describedby="caption-attachment-11826" class="size-full wp-image-11826" src="https://zappysys.com/blog/wp-content/uploads/2020/02/Downloaded-Mail-Attachments.png" alt="" width="1040" height="559" srcset="https://zappysys.com/blog/wp-content/uploads/2020/02/Downloaded-Mail-Attachments.png 1040w, https://zappysys.com/blog/wp-content/uploads/2020/02/Downloaded-Mail-Attachments-300x161.png 300w, https://zappysys.com/blog/wp-content/uploads/2020/02/Downloaded-Mail-Attachments-1024x550.png 1024w, https://zappysys.com/blog/wp-content/uploads/2020/02/Downloaded-Mail-Attachments-768x413.png 768w" sizes="(max-width: 1040px) 100vw, 1040px" /></a><p id="caption-attachment-11826" class="wp-caption-text">Downloaded Mail Attachments</p></div></li>
</ol>
<h2><span id="Conclusion">Conclusion</span></h2>
<p>After all, in this article, we learned how to make a Microsoft Graph API REST API call. We used the <a href="https://zappysys.com/products/ssis-powerpack/" target="_blank" rel="noopener">SSIS JSON / REST API Connector</a> to extract data from Outlook Mail using OAuth. Made the Get attachment API call using the <a href="https://zappysys.com/products/ssis-powerpack/ssis-web-api-destination-connector/" target="_blank" rel="noopener">Web API Destination</a> and parsed the JSON response using the <a href="https://zappysys.com/products/ssis-powerpack/ssis-json-parser-transform/" target="_blank" rel="noopener">JSON Parser</a>. And using the Native SSIS Export Column, we saved the export attachment&#8217;s bytes to a local file. To explore many other scenarios not discussed in this article, download <a href="https://zappysys.com/products/ssis-powerpack/">SSIS PowerPack from here (includes 70+ Components)</a>.</p>
<h2><span id="References">References</span></h2>
<p>Finally, you can use the following links for more information:</p>
<ul>
<li style="list-style-type: none;">
<ul>
<li>Help File: <a href="https://zappysys.com/onlinehelp/ssis-powerpack/scr/json-source.htm" target="_blank" rel="noopener">JSON Source(REST API or File)</a></li>
<li>Help File: <a href="https://zappysys.com/onlinehelp/ssis-powerpack/index.htm#page=ssis-web-api-destination.htm" target="_blank" rel="noopener">Web API Destination</a></li>
<li>Help File: <a href="https://zappysys.com/onlinehelp/ssis-powerpack/index.htm#page=ssis-json-parser-transform.htm" target="_blank" rel="noopener">JSON Parser Transform</a></li>
<li><a href="https://docs.microsoft.com/en-us/graph/overview" target="_blank" rel="noopener">Overview of the Microsoft Graph API</a></li>
</ul>
</li>
</ul>
<p>The post <a href="https://zappysys.com/blog/get-office-365-mail-attachments-using-ssis/">How to Get Office 365 Mail Attachments using SSIS</a> appeared first on <a href="https://zappysys.com/blog">ZappySys Blog</a>.</p>
]]></content:encoded>
					
		
		
			</item>
		<item>
		<title>Get Office 365 data in Power BI using Microsoft Graph API and ODBC</title>
		<link>https://zappysys.com/blog/get-office-365-data-in-power-bi-using-microsoft-graph-api-and-odbc/</link>
		
		<dc:creator><![CDATA[ZappySys]]></dc:creator>
		<pubDate>Wed, 19 Dec 2018 17:57:00 +0000</pubDate>
				<category><![CDATA[JSON File / REST API Driver]]></category>
		<category><![CDATA[ODBC App Integration]]></category>
		<category><![CDATA[ODBC Drivers]]></category>
		<category><![CDATA[ODBC PowerPack]]></category>
		<category><![CDATA[Reporting - Microsoft Power BI]]></category>
		<category><![CDATA[REST API]]></category>
		<category><![CDATA[XML File / SOAP API Driver]]></category>
		<category><![CDATA[calendar]]></category>
		<category><![CDATA[microsoft graph api]]></category>
		<category><![CDATA[office 365]]></category>
		<category><![CDATA[onedrive]]></category>
		<category><![CDATA[onenote]]></category>
		<category><![CDATA[power bi]]></category>
		<guid isPermaLink="false">https://zappysys.com/blog/?p=5661</guid>

					<description><![CDATA[<p>Introduction In this article, we will get Office 365  data in Power BI using Microsoft Graph API and ODBC drivers. Specifically, we will get Excel file data in OneDrive, events from a Calendar and finally, a list in a note in OneNote and then load that data into a Power BI report. We will achieve [&#8230;]</p>
<p>The post <a href="https://zappysys.com/blog/get-office-365-data-in-power-bi-using-microsoft-graph-api-and-odbc/">Get Office 365 data in Power BI using Microsoft Graph API and ODBC</a> appeared first on <a href="https://zappysys.com/blog">ZappySys Blog</a>.</p>
]]></description>
										<content:encoded><![CDATA[<h2>Introduction</h2>
<p style="text-align: justify;"><img loading="lazy" decoding="async" class="size-thumbnail wp-image-6204 alignleft" src="https://zappysys.com/blog/wp-content/uploads/2018/12/office-365-to-power-bi-150x150.png" alt="" width="150" height="150" srcset="https://zappysys.com/blog/wp-content/uploads/2018/12/office-365-to-power-bi-150x150.png 150w, https://zappysys.com/blog/wp-content/uploads/2018/12/office-365-to-power-bi-300x300.png 300w, https://zappysys.com/blog/wp-content/uploads/2018/12/office-365-to-power-bi.png 350w" sizes="(max-width: 150px) 100vw, 150px" />In this article, we will get <a href="https://www.office.com/" target="_blank" rel="noopener">Office 365</a>  data in Power BI using <a href="https://docs.microsoft.com/en-us/graph/overview" target="_blank" rel="noopener">Microsoft Graph API</a> and ODBC drivers. Specifically, we will get Excel file data in <a href="https://onedrive.live.com" target="_blank" rel="noopener">OneDrive</a>, events from a <a href="https://outlook.live.com/owa/?path=/calendar" target="_blank" rel="noopener">Calendar</a> and finally, a list in a note in <a href="https://www.onenote.com/" target="_blank" rel="noopener">OneNote</a> and then load that data into a Power BI report. We will achieve that by creating an ODBC data source using <a href="https://zappysys.com/products/odbc-powerpack/" target="_blank" rel="noopener">ZappySys ODBC PowerPack</a> and then querying corresponding <a href="https://docs.microsoft.com/en-us/graph/overview" target="_blank" rel="noopener">Microsoft Graph API</a> methods. ODBC PowerPack allows to query REST/SOAP APIs in an easy way and lets to view responses in a tabular format, which will be perfect to accomplish our goal.</p>
<p>&nbsp;</p>
<h2>Prerequisites</h2>
<ol>
<li>A Power BI account.</li>
<li>Wield basic Power BI skills.</li>
<li><a href="https://powerbi.microsoft.com/en-us/desktop/" target="_blank" rel="noopener">Power BI Desktop</a> installed.</li>
<li><a href="https://zappysys.com/products/odbc-powerpack/" target="_blank" rel="noopener">ZappySys ODBC PowerPack</a> installed.</li>
</ol>
<h2>Step By Step &#8211; Get Office 365 data in Power BI using Microsoft Graph API and ODBC</h2>
<div class="content_block" id="custom_post_widget-5670"><h2 style="text-align: left;">Register Application (OAuth2 App for Graph API)</h2>
<p style="text-align: left;">The first step to access any Office 365 API / Graph API is to register an OAuth App in the Azure Portal. After
following these steps, you will get the following two items to use in the next section:</p>

<ul style="text-align: left;">
 	<li>Application Id</li>
 	<li>Application Secret</li>
</ul>
<p style="text-align: left;">In this section, you will learn how to register a custom app in Microsoft Azure portal that will allow access to the
OneDrive. So, let's get started -</p>

<ol>
 	<li style="text-align: left;">Log into <a href="https://portal.azure.com/#blade/Microsoft_AAD_IAM/ActiveDirectoryMenuBlade/RegisteredApps">Microsoft
Azure portal</a> to register a custom app.</li>
 	<li style="text-align: left;">Register a new application by clicking New Registration link.<a href="https://zappysys.com/blog/wp-content/uploads/2020/07/NewRegistration.png"><img loading="lazy" decoding="async" class="size-full wp-image-9034" src="https://zappysys.com/blog/wp-content/uploads/2020/07/NewRegistration.png" alt="New App Registration in Azure portal" width="748" height="221" srcset="https://zappysys.com/blog/wp-content/uploads/2020/07/NewRegistration.png 748w, https://zappysys.com/blog/wp-content/uploads/2020/07/NewRegistration-300x89.png 300w" sizes="(max-width: 748px) 100vw, 748px" /></a></li>
 	<li style="text-align: left;">Provide the name of the custom app and who can access the app in the organization.<a href="https://zappysys.com/blog/wp-content/uploads/2020/07/RegisterOneDriveApp-1.jpg"><img loading="lazy" decoding="async" class="wp-image-9005 size-full" src="https://zappysys.com/blog/wp-content/uploads/2020/07/RegisterOneDriveApp-1.jpg" alt="Register an OneDrive App" width="610" height="518" srcset="https://zappysys.com/blog/wp-content/uploads/2020/07/RegisterOneDriveApp-1.jpg 610w, https://zappysys.com/blog/wp-content/uploads/2020/07/RegisterOneDriveApp-1-300x255.jpg 300w" sizes="(max-width: 610px) 100vw, 610px" /></a></li>
 	<li style="text-align: left;">Go to the App overview and add a Redirect URL.<a href="https://zappysys.com/blog/wp-content/uploads/2020/07/RedirectURI-1.jpg"><img loading="lazy" decoding="async" class="wp-image-9044 size-full" src="https://zappysys.com/blog/wp-content/uploads/2020/07/RedirectURI-1.jpg" alt="Add a Redirect URL" width="937" height="122" srcset="https://zappysys.com/blog/wp-content/uploads/2020/07/RedirectURI-1.jpg 937w, https://zappysys.com/blog/wp-content/uploads/2020/07/RedirectURI-1-300x39.jpg 300w, https://zappysys.com/blog/wp-content/uploads/2020/07/RedirectURI-1-768x100.jpg 768w" sizes="(max-width: 937px) 100vw, 937px" /></a></li>
 	<li style="text-align: left;">Click on "Add a Platform" under Platform Configuration section and then select "Web" under Web applications
section to enter a Redirect URL.
<pre class="lang:default decode:true">https://zappysys.com/oauth</pre>
<a href="https://zappysys.com/blog/wp-content/uploads/2020/07/RedirectURI2.jpg"><img loading="lazy" decoding="async" class="size-full wp-image-9007" src="https://zappysys.com/blog/wp-content/uploads/2020/07/RedirectURI2.jpg" alt="Redirect URL" width="466" height="564" srcset="https://zappysys.com/blog/wp-content/uploads/2020/07/RedirectURI2.jpg 466w, https://zappysys.com/blog/wp-content/uploads/2020/07/RedirectURI2-248x300.jpg 248w" sizes="(max-width: 466px) 100vw, 466px" /></a></li>
 	<li style="text-align: left;">Create a Client Secret key which will be used to Authenticate the custom Azure app.<a href="https://zappysys.com/blog/wp-content/uploads/2020/07/ClientSecret.jpg"><img loading="lazy" decoding="async" class="size-full wp-image-9010" src="https://zappysys.com/blog/wp-content/uploads/2020/07/ClientSecret.jpg" alt="Add a Client Secret" width="576" height="403" srcset="https://zappysys.com/blog/wp-content/uploads/2020/07/ClientSecret.jpg 576w, https://zappysys.com/blog/wp-content/uploads/2020/07/ClientSecret-300x210.jpg 300w" sizes="(max-width: 576px) 100vw, 576px" /></a><a href="https://zappysys.com/blog/wp-content/uploads/2020/07/ClientSecret2.jpg"><img loading="lazy" decoding="async" class="size-full wp-image-9011" src="https://zappysys.com/blog/wp-content/uploads/2020/07/ClientSecret2.jpg" alt="Secret Key Expiration Period" width="208" height="259" /></a><a href="https://zappysys.com/blog/wp-content/uploads/2020/07/ClientSecret3.jpg"><img loading="lazy" decoding="async" class="size-full wp-image-9012" src="https://zappysys.com/blog/wp-content/uploads/2020/07/ClientSecret3.jpg" alt="Specify Secret Key" width="1024" height="176" srcset="https://zappysys.com/blog/wp-content/uploads/2020/07/ClientSecret3.jpg 1024w, https://zappysys.com/blog/wp-content/uploads/2020/07/ClientSecret3-300x52.jpg 300w, https://zappysys.com/blog/wp-content/uploads/2020/07/ClientSecret3-768x132.jpg 768w" sizes="(max-width: 1024px) 100vw, 1024px" /></a>
<div><strong>Note</strong> - Take a note of <strong>Client Secret</strong>, it will be required while
configuring OAuth connection in the SSIS later</div></li>
 	<li style="text-align: left;">Add API Permissions.<a href="https://zappysys.com/blog/wp-content/uploads/2020/07/APIPermissions.jpg"><img loading="lazy" decoding="async" class="size-full wp-image-9008" src="https://zappysys.com/blog/wp-content/uploads/2020/07/APIPermissions.jpg" alt="OneDrive API Permissions" width="1291" height="415" /></a></li>
 	<li style="text-align: left;">Select following permissions from the Delegated Permissions section.
<pre class="lang:default decode:true">User.ReadBasic.All
Files.Read
offline_access</pre>
<a href="https://zappysys.com/blog/wp-content/uploads/2020/07/APIPermissions2.jpg"><img loading="lazy" decoding="async" class="size-full wp-image-9009" src="https://zappysys.com/blog/wp-content/uploads/2020/07/APIPermissions2.jpg" alt="Select Delegated Permissions" width="512" height="571" srcset="https://zappysys.com/blog/wp-content/uploads/2020/07/APIPermissions2.jpg 512w, https://zappysys.com/blog/wp-content/uploads/2020/07/APIPermissions2-269x300.jpg 269w" sizes="(max-width: 512px) 100vw, 512px" /></a></li>
 	<li>Take a note of Client ID, it will be required while configuring OAuth connection in the SSIS later.<a href="https://zappysys.com/blog/wp-content/uploads/2020/07/ClientSecret4.jpg"><img loading="lazy" decoding="async" class="wp-image-9013 size-full alignleft" src="https://zappysys.com/blog/wp-content/uploads/2020/07/ClientSecret4.jpg" alt="App Client ID" width="810" height="274" /></a></li>
</ol></div>
<div class="content_block" id="custom_post_widget-5914"><h3>Open ODBC Data Source Administrator</h3>
<ol>
 	<li>Hit <em>Windows Start</em> button and search for "odbc".</li>
 	<li>You will see two versions of <em>ODBC Data Source administrator</em>: <strong>64-bit </strong>and <strong>32-bit</strong>. Choose:
<ol>
 	<li style="list-style-type: none;">
<ul style="margin-left: 0px;">
 	<li>64-bit if your client application is a 64-bit program and you plan to create a <em>System DSN</em>.</li>
 	<li>32-bit if your client application is a 32-bit program and you plan to create a <em>System DSN</em>.</li>
 	<li>32-bit or 64-bit version if you plan to create a <em>User DSN</em>.</li>
</ul>
</li>
</ol>
<div class="wp-caption alignnone">

<img loading="lazy" decoding="async" class="alignnone size-full wp-image-6213" src="https://zappysys.com/blog/wp-content/uploads/2019/01/how-to-open-odbc-data-source-administrator-2.png" alt="" width="394" height="542" srcset="https://zappysys.com/blog/wp-content/uploads/2019/01/how-to-open-odbc-data-source-administrator-2.png 394w, https://zappysys.com/blog/wp-content/uploads/2019/01/how-to-open-odbc-data-source-administrator-2-218x300.png 218w" sizes="(max-width: 394px) 100vw, 394px" />
<p class="wp-caption-text">Windows ODBC Data Sources</p>

</div></li>
 	<li>Once you open, you should see a similar window:
<div class="wp-caption">

<img loading="lazy" decoding="async" class="alignnone size-full wp-image-5915" src="https://zappysys.com/blog/wp-content/uploads/2019/01/open-odbc-data-source-administrator-to-get-data-in-power-bi.png" alt="" width="594" height="421" srcset="https://zappysys.com/blog/wp-content/uploads/2019/01/open-odbc-data-source-administrator-to-get-data-in-power-bi.png 594w, https://zappysys.com/blog/wp-content/uploads/2019/01/open-odbc-data-source-administrator-to-get-data-in-power-bi-300x213.png 300w" sizes="(max-width: 594px) 100vw, 594px" />
<p class="wp-caption-text">ODBC Data Source Administrator</p>

</div></li>
</ol></div>
<h3>Set up an ODBC data source based on ZappySys JSON Driver</h3>
<h4>Add a data source</h4>
<div class="content_block" id="custom_post_widget-6052"><ol>
 	<li>Go to <em>System DSN</em> and press <em>Add</em> to add a system DSN. If you use apps like Power BI which needs access only your User account then you can create User DSN.<img loading="lazy" decoding="async" class="wp-image-2927 size-full" src="https://zappysys.com/blog/wp-content/uploads/2018/03/odb-data-source-administrator-add.png" alt="Create new ODBC DSN (System DSN Tab)" width="590" height="419" srcset="https://zappysys.com/blog/wp-content/uploads/2018/03/odb-data-source-administrator-add.png 590w, https://zappysys.com/blog/wp-content/uploads/2018/03/odb-data-source-administrator-add-300x213.png 300w" sizes="(max-width: 590px) 100vw, 590px" /></li>
 	<li>Add a data source based on <em>ZappySys JSON Driver</em>:
<a href="https://zappysys.com/blog/wp-content/uploads/2018/03/add-zappysys-json-driver.png"><img loading="lazy" decoding="async" class="wp-image-2923 size-full" src="https://zappysys.com/blog/wp-content/uploads/2018/03/add-zappysys-json-driver.png" alt="Add ZappySys JSON / REST Driver Connection" width="464" height="352" srcset="https://zappysys.com/blog/wp-content/uploads/2018/03/add-zappysys-json-driver.png 464w, https://zappysys.com/blog/wp-content/uploads/2018/03/add-zappysys-json-driver-300x228.png 300w" sizes="(max-width: 464px) 100vw, 464px" /></a></li>
</ol></div>
<h4>Configure the data source</h4>
<div class="content_block" id="custom_post_widget-6064"><ol>
 	<li>Once a window appears, give a name to the data source, e.g. <strong>System - JSON:
<img loading="lazy" decoding="async" class="alignnone size-full wp-image-6182" src="https://zappysys.com/blog/wp-content/uploads/2019/01/get-data-from-office-365-using-microsoft-graph-api-and-odbc-powerpack-1.png" alt="" width="697" height="745" srcset="https://zappysys.com/blog/wp-content/uploads/2019/01/get-data-from-office-365-using-microsoft-graph-api-and-odbc-powerpack-1.png 697w, https://zappysys.com/blog/wp-content/uploads/2019/01/get-data-from-office-365-using-microsoft-graph-api-and-odbc-powerpack-1-281x300.png 281w" sizes="(max-width: 697px) 100vw, 697px" />
</strong></li>
 	<li>Then input <strong>https://graph.microsoft.com/v1.0/me</strong> in the URL field.</li>
 	<li>Select <strong>OAuth</strong> as the <em>Connection Type</em>.</li>
 	<li>Click <strong>Click to Configure</strong> button/link to open OAuth configuration window.</li>
 	<li>Select <strong>Custom</strong> as <em>OAuth Provider</em>.</li>
 	<li>Then input <em>Client Id, Client Secret</em> which we got when created the Graph API application.</li>
 	<li>Set <strong>https://login.microsoftonline.com/common/oauth2/v2.0/authorize</strong> as <em>Authorization Url.</em></li>
 	<li>Set <strong>https://login.microsoftonline.com/common/oauth2/v2.0/token</strong> as <em>Access Token Url</em>.</li>
 	<li>In <em>Scopes / Permissions</em> section set these scopes, separated by a new line. E.g. <strong>offline_access</strong>, <strong>Files.Read.All</strong>, <strong>Calendars</strong>.<strong>Read</strong>, <strong>Notes.Read, User.Read</strong></li>
 	<li>In <em>Advanced </em>tab configure <em>Callback/Redirect Url </em>and set it to the one we configured in Graph API app:
<img loading="lazy" decoding="async" class="alignnone size-full wp-image-6060" src="https://zappysys.com/blog/wp-content/uploads/2018/12/oauth-callback-return-url-configuration-for-office-365-app-in-odbc-powerpack.png" alt="" width="586" height="271" srcset="https://zappysys.com/blog/wp-content/uploads/2018/12/oauth-callback-return-url-configuration-for-office-365-app-in-odbc-powerpack.png 586w, https://zappysys.com/blog/wp-content/uploads/2018/12/oauth-callback-return-url-configuration-for-office-365-app-in-odbc-powerpack-300x139.png 300w" sizes="(max-width: 586px) 100vw, 586px" /></li>
 	<li>Finally, click <strong>Generate Token </strong>button to generate a token.</li>
 	<li>Click <strong>OK</strong> to close the window.</li>
</ol></div>
<h3>Set up an ODBC data source based on ZappySys XML Driver</h3>
<div class="content_block" id="custom_post_widget-6075"><ol>
 	<li>Before adding another data source based on ZappySys XML Driver, copy the connection string of the data source we just created:
<img loading="lazy" decoding="async" class="wp-image-6062 size-full alignnone" style="margin-right: 100px;" src="https://zappysys.com/blog/wp-content/uploads/2018/12/copy-connection-string-of-odbc-datasource-for-office-365-e1547488424263.png" alt="" width="529" height="210" srcset="https://zappysys.com/blog/wp-content/uploads/2018/12/copy-connection-string-of-odbc-datasource-for-office-365-e1547488424263.png 529w, https://zappysys.com/blog/wp-content/uploads/2018/12/copy-connection-string-of-odbc-datasource-for-office-365-e1547488424263-300x119.png 300w" sizes="(max-width: 529px) 100vw, 529px" /></li>
 	<li>Close the window and then add a new data source, but this time based on <em>ZappySys XML Driver</em>.</li>
 	<li>Once a window is opened, give it a name, e.g. <strong>System - XML</strong>.</li>
 	<li>Then press <strong>Load connection string</strong> button to load the connection string.</li>
 	<li>Paste the copied connection string and replace JSON text to XML, so that you have <strong>{ ZappySys XML Driver }</strong> in <em>DRIVER</em> property.</li>
 	<li>Close the window.</li>
</ol>
<img loading="lazy" decoding="async" class="alignnone size-full wp-image-6184" src="https://zappysys.com/blog/wp-content/uploads/2019/01/load-connection-string-in-odbc-data-source-for-office-365-graph-api-app-1.png" alt="" width="652" height="416" srcset="https://zappysys.com/blog/wp-content/uploads/2019/01/load-connection-string-in-odbc-data-source-for-office-365-graph-api-app-1.png 652w, https://zappysys.com/blog/wp-content/uploads/2019/01/load-connection-string-in-odbc-data-source-for-office-365-graph-api-app-1-300x191.png 300w" sizes="(max-width: 652px) 100vw, 652px" /></div>
<h3>Create a Power BI report</h3>
<h4>Reading files from OneDrive (getting Excel data)</h4>
<p>Let&#8217;s say you have Stock.xlsx stored in <em>Sample Documents</em> folder, OneDrive with this kind of data and you want to show it in a Power BI report:</p>
<p><img loading="lazy" decoding="async" class="alignnone size-full wp-image-6081" src="https://zappysys.com/blog/wp-content/uploads/2018/12/stock.xlsx.png" alt="" width="261" height="151" /></p>
<p>To have that data in a Power BI report, perform these steps:</p>
<ol style="margin-left: 0;">
<li>Open Power BI Desktop and create a new Power BI report.</li>
<li>Create a data source based on <strong>System &#8211; JSON</strong> DSN (since we get a JSON response):<br />
<img loading="lazy" decoding="async" class="alignnone size-full wp-image-6191" style="border: 1px solid grey;" src="https://zappysys.com/blog/wp-content/uploads/2018/12/create-odbc-data-source-in-power-bi-report-to-get-office-365-data-2.png" alt="" width="695" height="518" srcset="https://zappysys.com/blog/wp-content/uploads/2018/12/create-odbc-data-source-in-power-bi-report-to-get-office-365-data-2.png 695w, https://zappysys.com/blog/wp-content/uploads/2018/12/create-odbc-data-source-in-power-bi-report-to-get-office-365-data-2-300x224.png 300w" sizes="(max-width: 695px) 100vw, 695px" /></li>
<li style="text-align: justify;">Then in <em>SQL statement</em> area enter this query:<br />
<code>SELECT * FROM $<br />
WITH(Src='https://graph.microsoft.com/v1.0/me/drive/root:/<strong>YOUR FOLDER</strong>/Stock.xlsx:/workbook/worksheets/<strong>SHEET NAME</strong>/usedRange'<br />
,Filter='$.values[1:]'<br />
,ArrayTransformType='TransformSimpleTwoDimensionalArray'<br />
,ArrayTransColumnNameFilter='$.values[0][*]'<br />
)<br />
</code>Using <em>WITH</em> clause lets us override the properties. You can generate the query above using the <em>Query Builder</em>:<br />
<img loading="lazy" decoding="async" class="alignnone size-full wp-image-6189" src="https://zappysys.com/blog/wp-content/uploads/2018/12/use-query-builder-in-odbc-powerpack-to-override-the-properties.png" alt="" width="545" height="297" srcset="https://zappysys.com/blog/wp-content/uploads/2018/12/use-query-builder-in-odbc-powerpack-to-override-the-properties.png 545w, https://zappysys.com/blog/wp-content/uploads/2018/12/use-query-builder-in-odbc-powerpack-to-override-the-properties-300x163.png 300w" sizes="(max-width: 545px) 100vw, 545px" />In this step we are overriding Url, Filter and array transformation fields you configured in JSON DSN. The <em>Src</em> value overrides the URL. The <em>Filter</em> property enables us to select the data we want to see in the report. We use <strong>[1:]</strong> in <strong>$.values[1:] </strong>to skip the first row because the first row contains the headers and we want only the data. You can configure this option in the <em>Filter Options</em> tab (<a href="https://goessner.net/articles/JsonPath/" target="_blank" rel="noopener">read more about JSON path</a>).We also have to make the transformation on the JSON and turn JSON arrays into rows. To accomplish that, we override <em>ArrayTransformType. </em>With <em>ArrayTransColumnNameFilter</em> property and <strong>[0][*]</strong> text, we specify that the first array of parent array will be the headers of the columns. You can read more about transformations in <a href="https://zappysys.com/blog/parse-multi-dimensional-json-array-ssis/" target="_blank" rel="noopener">Parse multi-dimensional JSON array</a> article.<div class="su-note"  style="border-color:#e5de9d;border-radius:3px;-moz-border-radius:3px;-webkit-border-radius:3px;"><div class="su-note-inner su-u-clearfix su-u-trim" style="background-color:#fff8b7;border-color:#ffffff;color:#333333;border-radius:3px;-moz-border-radius:3px;-webkit-border-radius:3px;"><strong>Note:</strong> Use <a href="https://developer.microsoft.com/en-us/graph/graph-explorer/" target="_blank" rel="noopener">Microsoft Graph API Explorer</a> to make a call and see what response you get. You can try calling <a href="https://docs.microsoft.com/en-us/graph/onedrive-concept-overview" target="_blank" rel="noopener">other OneDrive endpoints</a>.</div></div></li>
<li>Click <strong>OK</strong>.</li>
<li>Drag a table into the report, select the columns and you should see a similar view:<br />
<img loading="lazy" decoding="async" class="alignnone size-full wp-image-6087" src="https://zappysys.com/blog/wp-content/uploads/2018/12/get-excel-data-into-power-bi-using-odbc-powerpack-and-microsoft-graph-api-1.png" alt="" width="236" height="216" /></li>
</ol>
<h4>Reading calendar entries</h4>
<p>Now, let&#8217;s say you use a calendar in Office 365 and you want your appointments to be visible in a Power BI report:<br />
<img loading="lazy" decoding="async" class="alignnone size-full wp-image-6101" src="https://zappysys.com/blog/wp-content/uploads/2018/12/calendar-in-office-365.png" alt="" width="590" height="222" srcset="https://zappysys.com/blog/wp-content/uploads/2018/12/calendar-in-office-365.png 590w, https://zappysys.com/blog/wp-content/uploads/2018/12/calendar-in-office-365-300x113.png 300w" sizes="(max-width: 590px) 100vw, 590px" /></p>
<ol>
<li>To start, create a new Power BI report.</li>
<li>Then add a data source based on <strong>System &#8211; JSON </strong>DSN (again, we get the response in JSON):<br />
<img loading="lazy" decoding="async" class="alignnone size-full wp-image-6187" src="https://zappysys.com/blog/wp-content/uploads/2018/12/create-odbc-data-source-in-power-bi-report-to-get-calendar-events-in-office-365-b-1.png" alt="" width="701" height="524" srcset="https://zappysys.com/blog/wp-content/uploads/2018/12/create-odbc-data-source-in-power-bi-report-to-get-calendar-events-in-office-365-b-1.png 701w, https://zappysys.com/blog/wp-content/uploads/2018/12/create-odbc-data-source-in-power-bi-report-to-get-calendar-events-in-office-365-b-1-300x224.png 300w" sizes="(max-width: 701px) 100vw, 701px" /></li>
<li style="text-align: justify;">In <em>SQL statement</em> section enter this query:<br />
<code>SELECT * FROM $<br />
WITH(Src='https://graph.microsoft.com/v1.0/me/events?$select=subject,start,end,location'<br />
,Filter='$.value[*]'<br />
,Header='Prefer: outlook.timezone="FLE Standard Time"'<br />
)</code>Here we also are overriding <em>HTTP Header</em> so that we get the event times not in UTC/GMT but for the specified timezone. It must be specified in <strong>Prefer: outlook.timezone=&#8221;{time-zone-string}&#8221;</strong> format (check <a href="https://graph.microsoft.com/v1.0/me/outlook/supportedTimeZones" target="_blank" rel="noopener">an article</a> on how to get a list of supported time zones).<div class="su-note"  style="border-color:#e5de9d;border-radius:3px;-moz-border-radius:3px;-webkit-border-radius:3px;"><div class="su-note-inner su-u-clearfix su-u-trim" style="background-color:#fff8b7;border-color:#ffffff;color:#333333;border-radius:3px;-moz-border-radius:3px;-webkit-border-radius:3px;"><strong>Note:</strong> Use <a href="https://developer.microsoft.com/en-us/graph/graph-explorer/" target="_blank" rel="noopener">Microsoft Graph API Explorer</a> to make a call and see what response you get. You can try calling <a href="https://docs.microsoft.com/en-us/graph/outlook-calendar-concept-overview" target="_blank" rel="noopener">other Calendar endpoints</a>.</div></div></li>
<li>Click <strong>OK</strong>.</li>
<li>Drag a table control into the report, select several columns and you should see a similar view:<br />
<img loading="lazy" decoding="async" class="alignnone wp-image-6102 size-full" src="https://zappysys.com/blog/wp-content/uploads/2018/12/office-365-calendar-appointments-in-power-bi-report-retrieved-with-odbc-powerpack-e1547658449371.png" alt="" width="490" height="214" srcset="https://zappysys.com/blog/wp-content/uploads/2018/12/office-365-calendar-appointments-in-power-bi-report-retrieved-with-odbc-powerpack-e1547658449371.png 490w, https://zappysys.com/blog/wp-content/uploads/2018/12/office-365-calendar-appointments-in-power-bi-report-retrieved-with-odbc-powerpack-e1547658449371-300x131.png 300w" sizes="(max-width: 490px) 100vw, 490px" /></li>
</ol>
<h4>Reading notes from OneNote</h4>
<p>Suppose, you have these notes in OneNote and you want &#8220;<em>Groceries list</em>&#8221; to be shown in a Power BI report:</p>
<p><img loading="lazy" decoding="async" class="alignnone size-full wp-image-6114" src="https://zappysys.com/blog/wp-content/uploads/2018/12/notes-in-onenote.png" alt="" width="516" height="189" srcset="https://zappysys.com/blog/wp-content/uploads/2018/12/notes-in-onenote.png 516w, https://zappysys.com/blog/wp-content/uploads/2018/12/notes-in-onenote-300x110.png 300w" sizes="(max-width: 516px) 100vw, 516px" /></p>
<ol>
<li>First, we will need to find NOTE ID we are trying to get. To do that, open <em>ODBC Administrator</em>, find <strong>System &#8211; JSON</strong> data source and hit <strong>Configure</strong>.</li>
<li>Then go to <em>the Preview</em> tab, and input this SQL query and hit <strong>Preview Data</strong>:<br />
<code>SELECT * FROM $<br />
WITH (Src='https://graph.microsoft.com/v1.0/me/onenote/pages'<br />
,Filter='$.value[*]'<br />
)</code></li>
<li>Once you get a result set, find your note name and copy its ID:<br />
<img loading="lazy" decoding="async" class="alignnone size-full wp-image-6192" src="https://zappysys.com/blog/wp-content/uploads/2018/12/using-odbc-powerpack-get-note-id-in-onenote-part-of-office-365-1.png" alt="" width="676" height="593" srcset="https://zappysys.com/blog/wp-content/uploads/2018/12/using-odbc-powerpack-get-note-id-in-onenote-part-of-office-365-1.png 676w, https://zappysys.com/blog/wp-content/uploads/2018/12/using-odbc-powerpack-get-note-id-in-onenote-part-of-office-365-1-300x263.png 300w" sizes="(max-width: 676px) 100vw, 676px" /></li>
<li>Then create a new Power BI report.</li>
<li>Create a new data source based on <strong>System &#8211; XML</strong> DSN (we are using XML-based DSN because the response will be in HTML):<br />
<img loading="lazy" decoding="async" class="alignnone size-full wp-image-6193" src="https://zappysys.com/blog/wp-content/uploads/2018/12/create-odbc-data-source-in-power-bi-report-to-get-onenote-notes-in-office-365-1.png" alt="" width="701" height="524" srcset="https://zappysys.com/blog/wp-content/uploads/2018/12/create-odbc-data-source-in-power-bi-report-to-get-onenote-notes-in-office-365-1.png 701w, https://zappysys.com/blog/wp-content/uploads/2018/12/create-odbc-data-source-in-power-bi-report-to-get-onenote-notes-in-office-365-1-300x224.png 300w" sizes="(max-width: 701px) 100vw, 701px" /></li>
<li>In <em>SQL statement</em> section enter this query (use the NOTE ID you retrieved in the previous step):<br />
<code>SELECT * FROM $<br />
WITH(ElementsToTreatAsArray='div,p'<br />
,Src='https://graph.microsoft.com/v1.0/me/onenote/pages/<strong>NOTE ID</strong>/content'<br />
,Filter='$.html.body.div[0].p[1:]'<br />
)<br />
</code><br />
<div class="su-note"  style="border-color:#e5de9d;border-radius:3px;-moz-border-radius:3px;-webkit-border-radius:3px;"><div class="su-note-inner su-u-clearfix su-u-trim" style="background-color:#fff8b7;border-color:#ffffff;color:#333333;border-radius:3px;-moz-border-radius:3px;-webkit-border-radius:3px;"><strong>Note:</strong> Use <a href="https://developer.microsoft.com/en-us/graph/graph-explorer/" target="_blank" rel="noopener">Microsoft Graph API Explorer</a> to make a call and see what response you get. You can try calling <a href="https://docs.microsoft.com/en-us/graph/integrate-with-onenote" target="_blank" rel="noopener">other OneNote endpoints</a>.</div></div></li>
<li style="text-align: justify;">Click <strong>OK</strong>.</li>
<li>Drag and drop <em>Multi-row card</em> visual, select <strong>#text</strong> column and you should see a similar view:<br />
<img loading="lazy" decoding="async" class="alignnone size-full wp-image-6145" src="https://zappysys.com/blog/wp-content/uploads/2018/12/note-to-buy.png" alt="" width="288" height="288" srcset="https://zappysys.com/blog/wp-content/uploads/2018/12/note-to-buy.png 288w, https://zappysys.com/blog/wp-content/uploads/2018/12/note-to-buy-150x150.png 150w" sizes="(max-width: 288px) 100vw, 288px" /></li>
<li>We finished! Now you can publish your Power BI reports to Power BI service.</li>
</ol>
<div class="content_block" id="custom_post_widget-5891"><h2>Working with Gateways in Power BI (Schedule Import)</h2>
If the data needs to be updated, it is necessary to create a gateway on-premises. In this new section, we will install a Power BI Gateway and in the next section schedule it to update the REST API information.
<ol>
 	<li>In the last section, we Published the report. Power BI may ask you to <strong>SIGN IN.</strong>
<div class="wp-caption">

<a href="https://zappysys.com/blog/wp-content/uploads/2018/03/sign-in-power-bi.png"><img loading="lazy" decoding="async" class="size-full wp-image-2879" src="https://zappysys.com/blog/wp-content/uploads/2018/03/sign-in-power-bi.png" alt="Sign in Power BI" width="762" height="361" srcset="https://zappysys.com/blog/wp-content/uploads/2018/03/sign-in-power-bi.png 762w, https://zappysys.com/blog/wp-content/uploads/2018/03/sign-in-power-bi-300x142.png 300w" sizes="(max-width: 762px) 100vw, 762px" /></a>
<p class="wp-caption-text">Sign in in Power BI</p>

</div></li>
 	<li>Select the Workspace and select Datasets
<div class="wp-caption">

[caption id="attachment_10110" align="alignnone" width="702"]<a href="https://zappysys.com/blog/wp-content/uploads/2019/01/power-bi-my-workspace-dataset.png"><img loading="lazy" decoding="async" class="wp-image-10110 size-full" src="https://zappysys.com/blog/wp-content/uploads/2019/01/power-bi-my-workspace-dataset.png" alt="power-bi-my-workspace-dataset" width="702" height="372" srcset="https://zappysys.com/blog/wp-content/uploads/2019/01/power-bi-my-workspace-dataset.png 702w, https://zappysys.com/blog/wp-content/uploads/2019/01/power-bi-my-workspace-dataset-300x159.png 300w" sizes="(max-width: 702px) 100vw, 702px" /></a> Go to workspace and dataset[/caption]
<p class="wp-caption-text">Go to workspace and dataset</p>

</div></li>
 	<li>Right-click the report and select <strong>Settings</strong>.
<div class="wp-caption">

<a href="https://zappysys.com/blog/wp-content/uploads/2018/03/report-power-bi-settings.png"><img loading="lazy" decoding="async" class="size-full wp-image-2877" src="https://zappysys.com/blog/wp-content/uploads/2018/03/report-power-bi-settings.png" alt="Define settings for Power BI report" width="535" height="325" srcset="https://zappysys.com/blog/wp-content/uploads/2018/03/report-power-bi-settings.png 535w, https://zappysys.com/blog/wp-content/uploads/2018/03/report-power-bi-settings-300x182.png 300w" sizes="(max-width: 535px) 100vw, 535px" /></a>
<p class="wp-caption-text">Specify settings for the report</p>

</div></li>
 	<li>The system will ask for a Gateway. Stay here.
<div class="wp-caption">

<a href="https://zappysys.com/blog/wp-content/uploads/2018/03/add-power-bi-gateway.png"><img loading="lazy" decoding="async" class="size-full wp-image-2862" src="https://zappysys.com/blog/wp-content/uploads/2018/03/add-power-bi-gateway.png" alt="add power bi gateway" width="1068" height="380" srcset="https://zappysys.com/blog/wp-content/uploads/2018/03/add-power-bi-gateway.png 1068w, https://zappysys.com/blog/wp-content/uploads/2018/03/add-power-bi-gateway-300x107.png 300w, https://zappysys.com/blog/wp-content/uploads/2018/03/add-power-bi-gateway-768x273.png 768w, https://zappysys.com/blog/wp-content/uploads/2018/03/add-power-bi-gateway-1024x364.png 1024w" sizes="(max-width: 1068px) 100vw, 1068px" /></a>
<p class="wp-caption-text">Add Power BI Gateway</p>

</div></li>
 	<li>Use the following link to install a Data Gateway:
<pre class="lang:php highlight:0 decode:true">https://docs.microsoft.com/en-us/power-bi/service-gateway-onprem</pre>
</li>
 	<li>Run the installer and press <strong>Next</strong>
<div class="wp-caption">

<img loading="lazy" decoding="async" class="size-full wp-image-2888" src="https://zappysys.com/blog/wp-content/uploads/2018/03/on-premises-gateway-installer-PB.png" alt="Initial gateway window for installation" width="634" height="504" srcset="https://zappysys.com/blog/wp-content/uploads/2018/03/on-premises-gateway-installer-PB.png 634w, https://zappysys.com/blog/wp-content/uploads/2018/03/on-premises-gateway-installer-PB-300x238.png 300w" sizes="(max-width: 634px) 100vw, 634px" />
<p class="wp-caption-text">Gateway installer</p>

</div></li>
 	<li>Select the option On-premises data gateway (recommended). This option allows access to multiple users and can be used by more applications than Power BI.
<div class="wp-caption">

<a href="https://zappysys.com/blog/wp-content/uploads/2018/03/choose-power-bi-on-premises-data-pb.png"><img loading="lazy" decoding="async" class="size-full wp-image-2889" src="https://zappysys.com/blog/wp-content/uploads/2018/03/choose-power-bi-on-premises-data-pb.png" alt="Choose Power BI gateway" width="631" height="501" srcset="https://zappysys.com/blog/wp-content/uploads/2018/03/choose-power-bi-on-premises-data-pb.png 631w, https://zappysys.com/blog/wp-content/uploads/2018/03/choose-power-bi-on-premises-data-pb-300x238.png 300w" sizes="(max-width: 631px) 100vw, 631px" /></a>
<p class="wp-caption-text">Choose Power BI option</p>

</div></li>
 	<li>The installer will show a warning message.
<div class="wp-caption">

<a href="https://zappysys.com/blog/wp-content/uploads/2018/03/power-bi-gateway-warning-PB-msg.png"><img loading="lazy" decoding="async" class="size-full wp-image-2891" src="https://zappysys.com/blog/wp-content/uploads/2018/03/power-bi-gateway-warning-PB-msg.png" alt="Warning message gateway installation" width="628" height="447" srcset="https://zappysys.com/blog/wp-content/uploads/2018/03/power-bi-gateway-warning-PB-msg.png 628w, https://zappysys.com/blog/wp-content/uploads/2018/03/power-bi-gateway-warning-PB-msg-300x214.png 300w" sizes="(max-width: 628px) 100vw, 628px" /></a>
<p class="wp-caption-text">Warning message during installation</p>

</div></li>
 	<li>Select the path to install and check the I accept the terms.
<div class="wp-caption">

<a href="https://zappysys.com/blog/wp-content/uploads/2018/03/power-bi-gateway-installation-accept.png"><img loading="lazy" decoding="async" class="size-full wp-image-2916" src="https://zappysys.com/blog/wp-content/uploads/2018/03/power-bi-gateway-installation-accept.png" alt="accept terms" width="636" height="441" srcset="https://zappysys.com/blog/wp-content/uploads/2018/03/power-bi-gateway-installation-accept.png 636w, https://zappysys.com/blog/wp-content/uploads/2018/03/power-bi-gateway-installation-accept-300x208.png 300w" sizes="(max-width: 636px) 100vw, 636px" /></a>
<p class="wp-caption-text">Accept terms</p>

</div></li>
 	<li>Specify the email address to use the gateway.
<div class="wp-caption">

<a href="https://zappysys.com/blog/wp-content/uploads/2018/03/power-bi-gateway-installation-email-address.png"><img loading="lazy" decoding="async" class="size-full wp-image-2895" src="https://zappysys.com/blog/wp-content/uploads/2018/03/power-bi-gateway-installation-email-address.png" alt="Register email in gateway installation" width="627" height="578" srcset="https://zappysys.com/blog/wp-content/uploads/2018/03/power-bi-gateway-installation-email-address.png 627w, https://zappysys.com/blog/wp-content/uploads/2018/03/power-bi-gateway-installation-email-address-300x277.png 300w" sizes="(max-width: 627px) 100vw, 627px" /></a>
<p class="wp-caption-text">Register email address</p>

</div></li>
 	<li>After entering the email, write the gateway name and a recovery key. Make sure to confirm the recovery key.
<div class="wp-caption">

<a href="https://zappysys.com/blog/wp-content/uploads/2018/03/power-bi-gateway-name-recovery-key-confirm.png"><img loading="lazy" decoding="async" class="size-full wp-image-2896" src="https://zappysys.com/blog/wp-content/uploads/2018/03/power-bi-gateway-name-recovery-key-confirm.png" alt="Specify name and recovery key" width="629" height="487" srcset="https://zappysys.com/blog/wp-content/uploads/2018/03/power-bi-gateway-name-recovery-key-confirm.png 629w, https://zappysys.com/blog/wp-content/uploads/2018/03/power-bi-gateway-name-recovery-key-confirm-300x232.png 300w" sizes="(max-width: 629px) 100vw, 629px" /></a>
<p class="wp-caption-text">Enter recovery key</p>

</div></li>
</ol>
&nbsp;</div>
<div class="content_block" id="custom_post_widget-5892"><h2>Manage gateways and configure the schedule</h2>
Once that the gateway is installed we will configure it and add the connection strings.
<ol>
 	<li>The next step is to go to manage gateway
<div class="wp-caption">

<a href="https://zappysys.com/blog/wp-content/uploads/2018/03/power-bi-go-to-manage-gateway.png"><img loading="lazy" decoding="async" class="size-full wp-image-2912" src="https://zappysys.com/blog/wp-content/uploads/2018/03/power-bi-go-to-manage-gateway.png" alt="Power BI - Manage Gateway Setting" width="1068" height="380" srcset="https://zappysys.com/blog/wp-content/uploads/2018/03/power-bi-go-to-manage-gateway.png 1068w, https://zappysys.com/blog/wp-content/uploads/2018/03/power-bi-go-to-manage-gateway-300x107.png 300w, https://zappysys.com/blog/wp-content/uploads/2018/03/power-bi-go-to-manage-gateway-768x273.png 768w, https://zappysys.com/blog/wp-content/uploads/2018/03/power-bi-go-to-manage-gateway-1024x364.png 1024w" sizes="(max-width: 1068px) 100vw, 1068px" /></a>
<p class="wp-caption-text">Power BI - Manage Gateway Setting</p>

</div></li>
 	<li>In order to get the connection string, we will need the connection string of the ZappySys JSON Driver. In the first section of this post, we explained how to configure it. Press<strong> Copy Connection String</strong>
<div class="wp-caption">

<a href="https://zappysys.com/blog/wp-content/uploads/2018/03/power-bi-data-source-copy-connection-string.png"><img loading="lazy" decoding="async" class="size-full wp-image-2866" src="https://zappysys.com/blog/wp-content/uploads/2018/03/power-bi-data-source-copy-connection-string.png" alt="ZappySys connection properties" width="607" height="599" srcset="https://zappysys.com/blog/wp-content/uploads/2018/03/power-bi-data-source-copy-connection-string.png 607w, https://zappysys.com/blog/wp-content/uploads/2018/03/power-bi-data-source-copy-connection-string-300x296.png 300w" sizes="(max-width: 607px) 100vw, 607px" /></a>
<p class="wp-caption-text">Connection properties</p>

</div></li>
 	<li>Once that the data is copied, add a New data Source. In <strong>Data Source Name</strong>, enter the Data Source Name of the ZappySys JSON driver in step 13 and in Data Source Type, select ODBC. In connection string copy and paste from the clipboard of the step 13 and press <strong>Add</strong>.
<div class="wp-caption">

[caption id="attachment_10113" align="alignnone" width="720"]<a href="https://zappysys.com/blog/wp-content/uploads/2019/01/gateway-data-source-name-connection-string.png"><img loading="lazy" decoding="async" class="wp-image-10113 size-large" src="https://zappysys.com/blog/wp-content/uploads/2019/01/gateway-data-source-name-connection-string-1024x536.png" alt="gateway-data-source-name-connection-string" width="720" height="377" srcset="https://zappysys.com/blog/wp-content/uploads/2019/01/gateway-data-source-name-connection-string-1024x536.png 1024w, https://zappysys.com/blog/wp-content/uploads/2019/01/gateway-data-source-name-connection-string-300x157.png 300w, https://zappysys.com/blog/wp-content/uploads/2019/01/gateway-data-source-name-connection-string-768x402.png 768w, https://zappysys.com/blog/wp-content/uploads/2019/01/gateway-data-source-name-connection-string.png 1043w" sizes="(max-width: 720px) 100vw, 720px" /></a> ZappySys connection properties in Power BI[/caption]
<p class="wp-caption-text">ZappySys connection properties in Power BI</p>

</div></li>
 	<li>Once added the gateway. You can see the schedule refresh to <strong>On </strong>and Add another time to add the time where you want to refresh the data.
<div class="wp-caption">

<a href="https://zappysys.com/blog/wp-content/uploads/2018/03/power-bi-schedule.png"><img loading="lazy" decoding="async" class="size-full wp-image-2875" src="https://zappysys.com/blog/wp-content/uploads/2018/03/power-bi-schedule.png" alt="Schedule gateway" width="451" height="401" srcset="https://zappysys.com/blog/wp-content/uploads/2018/03/power-bi-schedule.png 451w, https://zappysys.com/blog/wp-content/uploads/2018/03/power-bi-schedule-300x267.png 300w" sizes="(max-width: 451px) 100vw, 451px" /></a>
<p class="wp-caption-text">Schedule gateway</p>

</div></li>
</ol>
&nbsp;</div>
<h2>Conclusion</h2>
<p style="text-align: justify;">Today we learned how to call Microsoft Graph API methods using <a href="https://zappysys.com/products/odbc-powerpack/" target="_blank" rel="noopener">ZappySys ODBC PowerPack</a> and load response data into Power BI without any ETL procedures. Particularly, we used OneDrive, Calendar and OneNote Graph API endpoints to achieve that. We created two ODBC data sources based on JSON and XML ODBC Driver to query those endpoints, which let us read data directly in a Power BI report. Finally, we examined how to refresh data source on Power BI using on-premises Power BI gateway.</p>
<h2>References</h2>
<p><a href="https://powerbi.microsoft.com/en-us/" target="_blank" rel="noopener">https://powerbi.microsoft.com/en-us/</a></p>
<p><a href="https://apps.dev.microsoft.com/" target="_blank" rel="noopener">https://apps.dev.microsoft.com/</a></p>
<p><a href="https://developer.microsoft.com/en-us/graph/graph-explorer/" target="_blank" rel="noopener">https://developer.microsoft.com/en-us/graph/graph-explorer/</a></p>
<p><a href="https://docs.microsoft.com/en-us/graph/overview" target="_blank" rel="noopener">https://docs.microsoft.com/en-us/graph/overview</a></p>
<p><a href="https://docs.microsoft.com/en-us/graph/onedrive-concept-overview" target="_blank" rel="noopener">https://docs.microsoft.com/en-us/graph/onedrive-concept-overview</a></p>
<p><a href="https://docs.microsoft.com/en-us/graph/outlook-calendar-concept-overview" target="_blank" rel="noopener">https://docs.microsoft.com/en-us/graph/outlook-calendar-concept-overview</a></p>
<p><a href="https://docs.microsoft.com/en-us/graph/integrate-with-onenote" target="_blank" rel="noopener">https://docs.microsoft.com/en-us/graph/integrate-with-onenote</a></p>
<p>&nbsp;</p>
<p>&nbsp;</p>
<p>The post <a href="https://zappysys.com/blog/get-office-365-data-in-power-bi-using-microsoft-graph-api-and-odbc/">Get Office 365 data in Power BI using Microsoft Graph API and ODBC</a> appeared first on <a href="https://zappysys.com/blog">ZappySys Blog</a>.</p>
]]></content:encoded>
					
		
		
			</item>
		<item>
		<title>Load data into Dynamics CRM using SSIS &#8211; Insert, Upsert, Delete, Update</title>
		<link>https://zappysys.com/blog/load-dynamics-crm-using-ssis-insert-upsert-delete-update/</link>
		
		<dc:creator><![CDATA[ZappySys]]></dc:creator>
		<pubDate>Thu, 05 Jul 2018 19:20:32 +0000</pubDate>
				<category><![CDATA[SSIS Dynamics CRM Destination]]></category>
		<category><![CDATA[dynamics crm]]></category>
		<category><![CDATA[office 365]]></category>
		<category><![CDATA[ssis]]></category>
		<category><![CDATA[upsert]]></category>
		<guid isPermaLink="false">https://zappysys.com/blog/?p=4318</guid>

					<description><![CDATA[<p>Introduction In our previous article, we talked about how to read from Dynamics CRM / Dataverse (Dynamics 365 / On-Premises CRM / PowerApp). Now let&#8217;s look at how to Load data into Dynamics CRM / Dataverse (Dynamics 365 / On-Premises CRM / PowerApp) using SSIS. We will see a few important aspects of loading data into Dynamics [&#8230;]</p>
<p>The post <a href="https://zappysys.com/blog/load-dynamics-crm-using-ssis-insert-upsert-delete-update/">Load data into Dynamics CRM using SSIS &#8211; Insert, Upsert, Delete, Update</a> appeared first on <a href="https://zappysys.com/blog">ZappySys Blog</a>.</p>
]]></description>
										<content:encoded><![CDATA[<h2>Introduction</h2>
<p><a href="https://zappysys.com/blog/wp-content/uploads/2018/05/dynamics-crm-365-logo-300x300.png"><img loading="lazy" decoding="async" class=" wp-image-3577 alignleft" src="https://zappysys.com/blog/wp-content/uploads/2018/05/dynamics-crm-365-logo-300x300.png" alt="" width="104" height="94" /></a>In our previous article, we talked about how to <a href="https://zappysys.com/blog/ssis-dynamics-crm-read-import-crm-365-onpremises/" target="_blank" rel="noopener">read from Dynamics CRM / Dataverse (Dynamics 365 / On-Premises CRM / PowerApp)</a>. Now let&#8217;s look at how to Load data into Dynamics CRM / Dataverse (Dynamics 365 / On-Premises CRM / PowerApp) using SSIS. We will see a few important aspects of loading data into Dynamics CRM / Dataverse Online (i.e. Dynamics 365) and On-premises / IFD (Internet facing hosted instance).</p>
<p>We will show you how to use <a href="https://zappysys.com/products/ssis-powerpack/ssis-dynamics-crm-destination-connector/" target="_blank" rel="noopener">SSIS Dynamics CRM Destination</a> connector for Bulk Insert, Update, Delete and Upsert Operations. This article uses Dynamics 365 Online for CRM Integration Examples but concepts are same for other types of installation (e.g. IFD or On-Premises)</p>
<h2>Requirements</h2>
<ol>
<li>Make sure you have SSIS Designer installed (i.e. <a href="https://docs.microsoft.com/en-us/sql/ssdt/download-sql-server-data-tools-ssdt?view=sql-server-2017" target="_blank" rel="noopener">SSDT-BI</a>)</li>
<li>Download and Installed <a href="https://zappysys.com/products/ssis-powerpack/" target="_blank" rel="noopener">ZappySys SSIS PowerPack</a> which includes an SSIS Dynamics CRM Connectors.</li>
<li>Finally, make sure you have Microsoft Dynamics CRM / Dataverse credentials handy.</li>
</ol>
<p>That&#8217;s it. So let&#8217;s get started.</p>
<h2>Video Tutorial &#8211; CRM Insert, Upsert, Delete, Update</h2>
<a href="https://zappysys.com/blog/load-dynamics-crm-using-ssis-insert-upsert-delete-update/"><img decoding="async" src="https://zappysys.com/blog/wp-content/plugins/wp-youtube-lyte/lyteCache.php?origThumbUrl=%2F%2Fi.ytimg.com%2Fvi%2FfBbRzTcd3fk%2Fhqdefault.jpg" alt="YouTube Video"></a><br /><br /></p>
<p>&nbsp;</p>
<h2>Getting Started</h2>
<p>In this section, we will see how to perform bulk insert, update delete and upsert operations using  <a href="https://zappysys.com/products/ssis-powerpack/ssis-dynamics-crm-destination-connector/" target="_blank" rel="noopener">SSIS Dynamics CRM Destination</a></p>
<h3>Configure SSIS Dynamics CRM / Dataverse Connection</h3>
<p>The first step to read or write Dynamics CRM / Dataverse data is to make sure we have working Dynamics CRM connection in SSIS.</p>
<ol>
<li>Create new or open existing SSIS Project in Visual Studio.</li>
<li>Open SSIS Package and Go to SSIS designer.</li>
<li>
        Right click in the connection manager panel and click <strong>New connection</strong>:</p>
<p>        <div id="attachment_3560" style="width: 756px" class="wp-caption alignnone"><a href="https://zappysys.com/blog/wp-content/uploads/2018/05/create-a-new-connection.jpg"><img loading="lazy" decoding="async" aria-describedby="caption-attachment-3560" class="size-full wp-image-3560" src="https://zappysys.com/blog/wp-content/uploads/2018/05/create-a-new-connection.jpg" alt="SSIS create a new connection CRM Dynamics" width="746" height="403" srcset="https://zappysys.com/blog/wp-content/uploads/2018/05/create-a-new-connection.jpg 746w, https://zappysys.com/blog/wp-content/uploads/2018/05/create-a-new-connection-300x162.jpg 300w" sizes="(max-width: 746px) 100vw, 746px" /></a><p id="caption-attachment-3560" class="wp-caption-text">Create a new SSIS Dynamics CRM / Dataverse Connection</p></div>
    </li>
<li>In the connection type selection, Select the <strong>ZS-DYNAMICS-CRM</strong> Connection.</li>
<li>
        We will use a <strong>CRM Online</strong> (Office 365) connection, <strong>region</strong>, a <strong>username</strong> and a <strong>password</strong> and select <strong>organization</strong> from the dropdown as below and then click <strong>Test connection</strong>:</p>
<p>        <div id="attachment_3559" style="width: 775px" class="wp-caption alignnone"><a href="https://zappysys.com/blog/wp-content/uploads/2018/05/ssis-credentials-zs.jpg"><img loading="lazy" decoding="async" aria-describedby="caption-attachment-3559" class="size-full wp-image-3559" src="https://zappysys.com/blog/wp-content/uploads/2018/05/ssis-credentials-zs.jpg" alt="SSIS Dynamics CRM / Dataverse credentials" width="765" height="633" srcset="https://zappysys.com/blog/wp-content/uploads/2018/05/ssis-credentials-zs.jpg 765w, https://zappysys.com/blog/wp-content/uploads/2018/05/ssis-credentials-zs-300x248.jpg 300w" sizes="(max-width: 765px) 100vw, 765px" /></a><p id="caption-attachment-3559" class="wp-caption-text">Configure Dynamics CRM / Dataverse Connection in SSIS</p></div>
    </li>
</ol>
<h3></h3>
<h3>Bulk Insert &#8211; SQL Server data Import into Dynamics CRM / Dataverse using SSIS</h3>
<p>Now, let&#8217;s see steps to do SQL Server data Import into Dynamics CRM / Dataverse using SSIS. Below steps assume you already have sample data in some SQL Server Table which will be used to create new CRM accounts. You can enter few account names you like to create in the CRM.</p>
<ol>
<li>Open SSIS Package and drag Data Flow task from Control Flow SSIS Toolbox</li>
<li>Go to data flow designer. Drag and drop OLEDB Source</li>
<li>
        Configure OLEDB Source to read from some sample data table (e.g. dbo.Accounts). If you want to be lazy and just test quickly you can use <a href="https://zappysys.com/products/ssis-powerpack/ssis-csv-file-source-flat-file-web-api/" target="_blank" rel="noopener">ZS CSV Source</a> (Direct Value Mode) instead of OLEDB Source.<strong>Sample Data May be like below</strong><br />
<pre class="crayon-plain-tag">name,address1_city,address1_country
Flipkart,Bengaluru,India
Microsoft,seattle,USA
Nokia,Espoo,Finland</pre>
        Once you configure Source (Connection, Table Name etc.) click OK to save it.</p>
<p>        <div id="attachment_4351" style="width: 785px" class="wp-caption alignnone"><a href="https://zappysys.com/blog/wp-content/uploads/2018/07/ssis-insert-accounts-to-dynamics-crm-online-365.png"><img loading="lazy" decoding="async" aria-describedby="caption-attachment-4351" class="size-full wp-image-4351" src="https://zappysys.com/blog/wp-content/uploads/2018/07/ssis-insert-accounts-to-dynamics-crm-online-365.png" alt="CSV Source - Sample Accounts for CRM Insert Demo" width="775" height="602" srcset="https://zappysys.com/blog/wp-content/uploads/2018/07/ssis-insert-accounts-to-dynamics-crm-online-365.png 775w, https://zappysys.com/blog/wp-content/uploads/2018/07/ssis-insert-accounts-to-dynamics-crm-online-365-300x233.png 300w, https://zappysys.com/blog/wp-content/uploads/2018/07/ssis-insert-accounts-to-dynamics-crm-online-365-768x597.png 768w" sizes="(max-width: 775px) 100vw, 775px" /></a><p id="caption-attachment-4351" class="wp-caption-text">CSV Source &#8211; Sample Accounts for CRM Insert Demo</p></div>
    </li>
<li>Drag and drop  <a href="https://zappysys.com/products/ssis-powerpack/ssis-dynamics-crm-destination-connector/" target="_blank" rel="noopener">ZS Dynamics CRM Destination</a> from the toolbox.</li>
<li>Connect Source to your Destination component.</li>
<li>Double click CRM destination to configure it.</li>
<li>
        On the Connection Managers tab, Select Dynamics CRM / Dataverse connection we created in the previous section.</p>
<p>        <div id="attachment_4353" style="width: 526px" class="wp-caption alignnone"><a href="https://zappysys.com/blog/wp-content/uploads/2018/07/ssis-dynamics-crm-destination-select-connection.png"><img loading="lazy" decoding="async" aria-describedby="caption-attachment-4353" class="size-full wp-image-4353" src="https://zappysys.com/blog/wp-content/uploads/2018/07/ssis-dynamics-crm-destination-select-connection.png" alt="Select Connection for Dynamics CRM / Dataverse Destination" width="516" height="286" srcset="https://zappysys.com/blog/wp-content/uploads/2018/07/ssis-dynamics-crm-destination-select-connection.png 516w, https://zappysys.com/blog/wp-content/uploads/2018/07/ssis-dynamics-crm-destination-select-connection-300x166.png 300w" sizes="(max-width: 516px) 100vw, 516px" /></a><p id="caption-attachment-4353" class="wp-caption-text">Select Connection for Dynamics CRM / Dataverse Destination</p></div>
    </li>
<li>
        On the Component Properties Tab Select <strong>Table Name</strong>.</p>
<p>        <div id="attachment_4354" style="width: 807px" class="wp-caption alignnone"><a href="https://zappysys.com/blog/wp-content/uploads/2018/07/ssis-dynamics-crm-insert-records-settings.png"><img loading="lazy" decoding="async" aria-describedby="caption-attachment-4354" class="size-full wp-image-4354" src="https://zappysys.com/blog/wp-content/uploads/2018/07/ssis-dynamics-crm-insert-records-settings.png" alt="Select Target Table for Dynamics CRM / Dataverse Insert" width="797" height="429" srcset="https://zappysys.com/blog/wp-content/uploads/2018/07/ssis-dynamics-crm-insert-records-settings.png 797w, https://zappysys.com/blog/wp-content/uploads/2018/07/ssis-dynamics-crm-insert-records-settings-300x161.png 300w, https://zappysys.com/blog/wp-content/uploads/2018/07/ssis-dynamics-crm-insert-records-settings-768x413.png 768w" sizes="(max-width: 797px) 100vw, 797px" /></a><p id="caption-attachment-4354" class="wp-caption-text">Select Target Table for Dynamics CRM / Dataverse Insert</p></div>
    </li>
<li>
        On the Mapping Tab map few columns (e.g.  <strong>name</strong>, <strong>address1_city, </strong>and <strong><strong><strong>address1_country)</strong></strong></strong></p>
<p>        <div id="attachment_4355" style="width: 792px" class="wp-caption alignnone"><a href="https://zappysys.com/blog/wp-content/uploads/2018/07/ssis-dynamics-crm-target-column-mappings.png"><img loading="lazy" decoding="async" aria-describedby="caption-attachment-4355" class="size-full wp-image-4355" src="https://zappysys.com/blog/wp-content/uploads/2018/07/ssis-dynamics-crm-target-column-mappings.png" alt="Configure Target Column Mapping for CRM Data Load" width="782" height="519" srcset="https://zappysys.com/blog/wp-content/uploads/2018/07/ssis-dynamics-crm-target-column-mappings.png 782w, https://zappysys.com/blog/wp-content/uploads/2018/07/ssis-dynamics-crm-target-column-mappings-300x199.png 300w, https://zappysys.com/blog/wp-content/uploads/2018/07/ssis-dynamics-crm-target-column-mappings-768x510.png 768w, https://zappysys.com/blog/wp-content/uploads/2018/07/ssis-dynamics-crm-target-column-mappings-272x182.png 272w" sizes="(max-width: 782px) 100vw, 782px" /></a><p id="caption-attachment-4355" class="wp-caption-text">Configure Target Column Mapping for CRM Data Load</p></div>
    </li>
<li>Click OK to save CRM destination.</li>
<li>
        Right click in the data flow designer, click Execute Task</p>
<p>        <div id="attachment_4356" style="width: 519px" class="wp-caption alignnone"><a href="https://zappysys.com/blog/wp-content/uploads/2018/07/ssis-loading-data-into-dynamics-crm-online.png"><img loading="lazy" decoding="async" aria-describedby="caption-attachment-4356" class="wp-image-4356 size-full" src="https://zappysys.com/blog/wp-content/uploads/2018/07/ssis-loading-data-into-dynamics-crm-online.png" alt="Execute SSIS Package - Import into Dynamics CRM / Dataverse using SSIS " width="509" height="224" srcset="https://zappysys.com/blog/wp-content/uploads/2018/07/ssis-loading-data-into-dynamics-crm-online.png 509w, https://zappysys.com/blog/wp-content/uploads/2018/07/ssis-loading-data-into-dynamics-crm-online-300x132.png 300w" sizes="(max-width: 509px) 100vw, 509px" /></a><p id="caption-attachment-4356" class="wp-caption-text">Execute SSIS Package &#8211; Loading Data into Dynamics CRM / Dataverse from CSV / SQL Server</p></div>
    </li>
</ol>
<h3>Bulk Upsert &#8211; Update or Insert Dynamics CRM / Dataverse Records in SSIS</h3>
<p>In the previous section we saw how to Insert New records. However sometimes you want to Upsert (Insert or Update). So if record already exists Update else Insert. In order to achieve this you have to set two additional attributes. For CRM Upsert you have to perform few changes to previous steps</p>
<h4>Create Alternate Key for CRM Upsert</h4>
<p>To perform Upsert operation you can map Table&#8217;s Primary Key or Alternate Key. Primary Key usually starts with table name and ends with &#8220;id&#8221; (e.g. for account table its accountid ).</p>
<p>Many times Source system don&#8217;t have CRM Table Primary Key. In such case you may use Alternate Key in the mapping (JOIN Key). To use Alternate key for Upsert you have first define Alternate Key in CRM Portal. <a href="https://technet.microsoft.com/library/29e53691-0b18-4fde-a1d0-7490aa227898.aspx" target="_blank" rel="noopener">Check this link for exact steps</a>.</p>
<div id="attachment_4359" style="width: 1056px" class="wp-caption alignnone"><a href="https://zappysys.com/blog/wp-content/uploads/2018/07/dynamics-crm-365-create-alternate-key-upsert-records-update-insert-data.png"><img loading="lazy" decoding="async" aria-describedby="caption-attachment-4359" class="size-full wp-image-4359" src="https://zappysys.com/blog/wp-content/uploads/2018/07/dynamics-crm-365-create-alternate-key-upsert-records-update-insert-data.png" alt="Create Alternate Key for Dynamics CRM / Dataverse Online Table (Useful for Update or Upsert Operation)" width="1046" height="522" srcset="https://zappysys.com/blog/wp-content/uploads/2018/07/dynamics-crm-365-create-alternate-key-upsert-records-update-insert-data.png 1046w, https://zappysys.com/blog/wp-content/uploads/2018/07/dynamics-crm-365-create-alternate-key-upsert-records-update-insert-data-300x150.png 300w, https://zappysys.com/blog/wp-content/uploads/2018/07/dynamics-crm-365-create-alternate-key-upsert-records-update-insert-data-768x383.png 768w, https://zappysys.com/blog/wp-content/uploads/2018/07/dynamics-crm-365-create-alternate-key-upsert-records-update-insert-data-1024x511.png 1024w, https://zappysys.com/blog/wp-content/uploads/2018/07/dynamics-crm-365-create-alternate-key-upsert-records-update-insert-data-960x480.png 960w" sizes="(max-width: 1046px) 100vw, 1046px" /></a><p id="caption-attachment-4359" class="wp-caption-text">Create Alternate Key for Dynamics CRM / Dataverse Online Table (Useful for Update or Upsert Operation)</p></div>
<h4>Configure SSIS CRM Destination for Upsert</h4>
<ol>
<li>Double click CRM destination. On the Component Properties Tab, Change Operation to <strong>UpdateOrInsert</strong></li>
<li>
        Specify <strong>UpsertKeyField</strong> to either Table&#8217;s Primary Key Column Name or Alternate Key Name.</p>
<p>        <div id="attachment_4360" style="width: 932px" class="wp-caption alignnone"><a href="https://zappysys.com/blog/wp-content/uploads/2018/07/ssis-dynamics-crm-upsert-update-insert-use-alternate-key-field.png"><img loading="lazy" decoding="async" aria-describedby="caption-attachment-4360" class="size-full wp-image-4360" src="https://zappysys.com/blog/wp-content/uploads/2018/07/ssis-dynamics-crm-upsert-update-insert-use-alternate-key-field.png" alt="Dynamics CRM / Dataverse Upsert using SSIS CRM Destination (Specify Alternate Key / Primary Key)" width="922" height="740" srcset="https://zappysys.com/blog/wp-content/uploads/2018/07/ssis-dynamics-crm-upsert-update-insert-use-alternate-key-field.png 922w, https://zappysys.com/blog/wp-content/uploads/2018/07/ssis-dynamics-crm-upsert-update-insert-use-alternate-key-field-300x241.png 300w, https://zappysys.com/blog/wp-content/uploads/2018/07/ssis-dynamics-crm-upsert-update-insert-use-alternate-key-field-768x616.png 768w" sizes="(max-width: 922px) 100vw, 922px" /></a><p id="caption-attachment-4360" class="wp-caption-text">Dynamics CRM / Dataverse Upsert Records using SSIS CRM Destination (Specify Alternate Key / Primary Key)</p></div>
    </li>
<li>
        Now go to Mappings tab and confirm Key field is mapped.</p>
<p>        <div id="attachment_4361" style="width: 866px" class="wp-caption alignnone"><a href="https://zappysys.com/blog/wp-content/uploads/2018/07/ssis-dynamics-crm-upsert-mappings.png"><img loading="lazy" decoding="async" aria-describedby="caption-attachment-4361" class="size-full wp-image-4361" src="https://zappysys.com/blog/wp-content/uploads/2018/07/ssis-dynamics-crm-upsert-mappings.png" alt="Configure Dynamics CRM / Dataverse Mapping for Upsert in SSIS" width="856" height="642" srcset="https://zappysys.com/blog/wp-content/uploads/2018/07/ssis-dynamics-crm-upsert-mappings.png 856w, https://zappysys.com/blog/wp-content/uploads/2018/07/ssis-dynamics-crm-upsert-mappings-300x225.png 300w, https://zappysys.com/blog/wp-content/uploads/2018/07/ssis-dynamics-crm-upsert-mappings-768x576.png 768w" sizes="(max-width: 856px) 100vw, 856px" /></a><p id="caption-attachment-4361" class="wp-caption-text">Configure Dynamics CRM / Dataverse Mapping for Upsert in SSIS</p></div>
    </li>
<li>Click OK and Run Package to test CRM Upsert Operation.</li>
</ol>
<p>&nbsp;</p>
<div class="su-note"  style="border-color:#e5dd9d;border-radius:3px;-moz-border-radius:3px;-webkit-border-radius:3px;"><div class="su-note-inner su-u-clearfix su-u-trim" style="background-color:#FFF7B7;border-color:#ffffff;color:#333333;border-radius:3px;-moz-border-radius:3px;-webkit-border-radius:3px;">If you want to use primary key for Upsert or Update Operation and not sure correct column name then you may use <a href="//zappysys.com/products/ssis-powerpack/ssis-dynamics-crm-source-connector/" target="_blank" rel="noopener">ZappySys Dynamics CRM / Dataverse Source</a> FetchXml Query Mode and check Object Browser (Table Info Tab &gt;&gt; <strong>PrimaryIdAttribute</strong> in the grid).</p>
<p>Primary Key name usually starts with table name and ends with &#8220;id&#8221; (e.g. for account table its <strong>accountid</strong> ).</p>
<div id="attachment_4358" style="width: 602px" class="wp-caption alignnone"><a href="https://zappysys.com/blog/wp-content/uploads/2018/07/dynamics-crm-find-primarykey-column.png"><img loading="lazy" decoding="async" aria-describedby="caption-attachment-4358" class=" wp-image-4358" src="https://zappysys.com/blog/wp-content/uploads/2018/07/dynamics-crm-find-primarykey-column.png" alt="Find Primary Key for Dynamics CRM / Dataverse Table" width="592" height="424" srcset="https://zappysys.com/blog/wp-content/uploads/2018/07/dynamics-crm-find-primarykey-column.png 792w, https://zappysys.com/blog/wp-content/uploads/2018/07/dynamics-crm-find-primarykey-column-300x215.png 300w, https://zappysys.com/blog/wp-content/uploads/2018/07/dynamics-crm-find-primarykey-column-768x550.png 768w" sizes="(max-width: 592px) 100vw, 592px" /></a><p id="caption-attachment-4358" class="wp-caption-text">Find Primary Key for Dynamics CRM / Dataverse Table</p></div>
</div></div>
<h4>Handling Inserted / Updated Records Output</h4>
<p>Now lets look at how to detect which records got inserted and which records got Update? In Upsert Mode each record can be directed to one of the following three Outputs.</p>
<ul>
<li>Inserted Records [Blue Arrow]</li>
<li>Updated Records [Blue Arrow]</li>
<li>Records with Error [Red Arrow]</li>
</ul>
<p>You can select Red or Blue arrow coming out from CRM Destination component. Drag and drop output arrow on any down stream component.</p>
<h3>Bulk Update &#8211; Modify Dynamics CRM / Dataverse Records in SSIS</h3>
<p>If you want to do bulk Update its very same steps as Upsert Operation except you have to set <strong>Operation = Update</strong> in the properties grid. For Key field you have to set primary key or Alternate Key.</p>
<div id="attachment_4362" style="width: 482px" class="wp-caption alignnone"><a href="https://zappysys.com/blog/wp-content/uploads/2018/07/ssis-dynamics-crm-update-records.png"><img loading="lazy" decoding="async" aria-describedby="caption-attachment-4362" class="size-full wp-image-4362" src="https://zappysys.com/blog/wp-content/uploads/2018/07/ssis-dynamics-crm-update-records.png" alt="Dynamics CRM / Dataverse Update in SSIS" width="472" height="474" srcset="https://zappysys.com/blog/wp-content/uploads/2018/07/ssis-dynamics-crm-update-records.png 472w, https://zappysys.com/blog/wp-content/uploads/2018/07/ssis-dynamics-crm-update-records-150x150.png 150w, https://zappysys.com/blog/wp-content/uploads/2018/07/ssis-dynamics-crm-update-records-300x300.png 300w" sizes="(max-width: 472px) 100vw, 472px" /></a><p id="caption-attachment-4362" class="wp-caption-text">Dynamics CRM / Dataverse Update in SSIS</p></div>
<h3>Bulk Delete &#8211; Delete Dynamics CRM / Dataverse Records in SSIS</h3>
<p>Bulk delete doesn&#8217;t require many settings. All you have to change is <strong>Operation = Delete</strong> on Component Properties Screen. On the Mapping Screen Map only one column (Primary Key). If you are not sure which one is primary key please refer to the previous section (Upsert Operation).</p>
<div id="attachment_4363" style="width: 687px" class="wp-caption alignnone"><a href="https://zappysys.com/blog/wp-content/uploads/2018/07/ssis-dynamics-crm-delete.png"><img loading="lazy" decoding="async" aria-describedby="caption-attachment-4363" class="size-full wp-image-4363" src="https://zappysys.com/blog/wp-content/uploads/2018/07/ssis-dynamics-crm-delete.png" alt="Delete records from Dynamics CRM / Dataverse Online using SSIS (Primary Key mapping for CRM Bulk Delete)" width="677" height="483" srcset="https://zappysys.com/blog/wp-content/uploads/2018/07/ssis-dynamics-crm-delete.png 677w, https://zappysys.com/blog/wp-content/uploads/2018/07/ssis-dynamics-crm-delete-300x214.png 300w" sizes="(max-width: 677px) 100vw, 677px" /></a><p id="caption-attachment-4363" class="wp-caption-text">Delete records from Dynamics CRM / Dataverse Online using SSIS (Primary Key mapping for CRM Bulk Delete)</p></div>
<p>Some times you may get below errors. If you get this error make sure you delete all child records first before deleting parent. For example if you are deleting account then make sure you have to delete leads / contacts for that account or update leads / contacts so they don&#8217;t refer to account being deleted.</p><pre class="crayon-plain-tag">Error: 0xC0047062 at Dynamics CRM / Dataverse Bulk Delete, Delete Accounts [2]: System.Exception: Exception: The object you tried to delete is associated with another object and cannot be deleted.
Error Details: 
ApiExceptionSourceKey=Plugin/Microsoft.Crm.Common.ObjectModel.AccountService</pre><p>
<h2>Error Handling</h2>
<p>Many times you want to ignore bad records and continue processing good records. In such case you can use Dynamics CRM / Dataverse Error Output. Just grad Red arrow from CRM Destination and Drop on target component. Select Redirect Option for Error , Truncation both and Click OK.</p>
<p>Once you set Error Handling your component will continue to run without failing whole data flow. Later you can review errors (if you saving to destination).</p>
<div id="attachment_4364" style="width: 863px" class="wp-caption alignnone"><a href="https://zappysys.com/blog/wp-content/uploads/2018/07/ssis-dynamics-crm-destination-configure-error-output.png"><img loading="lazy" decoding="async" aria-describedby="caption-attachment-4364" class="size-full wp-image-4364" src="https://zappysys.com/blog/wp-content/uploads/2018/07/ssis-dynamics-crm-destination-configure-error-output.png" alt="Configure Error Handling in SSIS Dynamics CRM / Dataverse Destination" width="853" height="801" srcset="https://zappysys.com/blog/wp-content/uploads/2018/07/ssis-dynamics-crm-destination-configure-error-output.png 853w, https://zappysys.com/blog/wp-content/uploads/2018/07/ssis-dynamics-crm-destination-configure-error-output-300x282.png 300w, https://zappysys.com/blog/wp-content/uploads/2018/07/ssis-dynamics-crm-destination-configure-error-output-768x721.png 768w" sizes="(max-width: 853px) 100vw, 853px" /></a><p id="caption-attachment-4364" class="wp-caption-text">Configure Error Handling in SSIS Dynamics CRM / Dataverse Destination</p></div>
<p>&nbsp;</p>
<div id="attachment_4365" style="width: 853px" class="wp-caption alignnone"><a href="https://zappysys.com/blog/wp-content/uploads/2018/07/insert-dynamics-crm-records-ssis.png"><img loading="lazy" decoding="async" aria-describedby="caption-attachment-4365" class="size-full wp-image-4365" src="https://zappysys.com/blog/wp-content/uploads/2018/07/insert-dynamics-crm-records-ssis.png" alt="Loading records into Dynamics CRM / Dataverse Table using SSIS . Redirect Bad rows to Error Output." width="843" height="422" srcset="https://zappysys.com/blog/wp-content/uploads/2018/07/insert-dynamics-crm-records-ssis.png 843w, https://zappysys.com/blog/wp-content/uploads/2018/07/insert-dynamics-crm-records-ssis-300x150.png 300w, https://zappysys.com/blog/wp-content/uploads/2018/07/insert-dynamics-crm-records-ssis-768x384.png 768w" sizes="(max-width: 843px) 100vw, 843px" /></a><p id="caption-attachment-4365" class="wp-caption-text">Loading records into Dynamics CRM / Dataverse Table using SSIS . Redirect Bad rows to Error Output.</p></div>
<h2>Handling Special Data Types (PartyList, Lookup, PickList)</h2>
<p>Certain datatypes in CRM requires special handling. <a href="https://zappysys.zendesk.com/hc/en-us/articles/360004361833-How-to-handle-Dynamics-CRM-PartyList-Lookup-and-PickList-datatypes-in-SSIS" target="_blank" rel="noopener">Check this article</a> to learn more about how to insert data into columns with <strong>PartyList</strong>, <strong>Lookup</strong> or <strong>PickList</strong> field.</p>
<h2>Conclusion</h2>
<p>In this article, We have seen how easy it is to integrate SQL Server data with Dynamics CRM / Dataverse. Using drag and drop connector you can perform Bulk insert, update, delete and Upsert operations. Download <a href="https://zappysys.com/products/ssis-powerpack/" target="_blank" rel="noopener">ZappySys SSIS PowerPack</a> to learn more about other possible scenarios which are not discussed in this article.</p>
<p>The post <a href="https://zappysys.com/blog/load-dynamics-crm-using-ssis-insert-upsert-delete-update/">Load data into Dynamics CRM using SSIS &#8211; Insert, Upsert, Delete, Update</a> appeared first on <a href="https://zappysys.com/blog">ZappySys Blog</a>.</p>
]]></content:encoded>
					
		
		
			</item>
		<item>
		<title>SSIS Dynamics CRM / Dataverse &#8211; Read / Import data into SQL Server</title>
		<link>https://zappysys.com/blog/ssis-dynamics-crm-read-import-crm-365-onpremises/</link>
		
		<dc:creator><![CDATA[ZappySys Team]]></dc:creator>
		<pubDate>Tue, 15 May 2018 20:36:40 +0000</pubDate>
				<category><![CDATA[SSIS Dynamics CRM Source]]></category>
		<category><![CDATA[dynamics crm]]></category>
		<category><![CDATA[office 365]]></category>
		<category><![CDATA[ssis]]></category>
		<guid isPermaLink="false">https://zappysys.com/blog/?p=3504</guid>

					<description><![CDATA[<p>Introduction Today Microsoft Dynamics CRM / Dataverse (Dynamics 365 / On-Premises CRM / PowerApp) is one of the most popular CRMs in the world. SSIS Dynamics CRM / Dataverse (Dynamics 365 / On-Premises CRM / PowerApp) read operation can be achieved using Dynamics CRM / Dataverse Source Connector. It allows connecting to Dynamics CRM / [&#8230;]</p>
<p>The post <a href="https://zappysys.com/blog/ssis-dynamics-crm-read-import-crm-365-onpremises/">SSIS Dynamics CRM / Dataverse &#8211; Read / Import data into SQL Server</a> appeared first on <a href="https://zappysys.com/blog">ZappySys Blog</a>.</p>
]]></description>
										<content:encoded><![CDATA[<h2>Introduction</h2>
<p><a href="https://zappysys.com/blog/wp-content/uploads/2018/05/dynamics-crm-365-logo-300x300.png"><img loading="lazy" decoding="async" class=" wp-image-3577 alignleft" src="https://zappysys.com/blog/wp-content/uploads/2018/05/dynamics-crm-365-logo-300x300.png" alt="" width="178" height="160" /></a>Today Microsoft Dynamics CRM / Dataverse (Dynamics 365 / On-Premises CRM / PowerApp) is one of the most popular CRMs in the world. SSIS Dynamics CRM / Dataverse (Dynamics 365 / On-Premises CRM / PowerApp) read operation can be achieved using <a href="https://zappysys.com/products/ssis-powerpack/ssis-dynamics-crm-source-connector/" target="_blank" rel="noopener">Dynamics CRM / Dataverse Source Connector</a>. It allows connecting to <strong>Dynamics CRM / Dataverse 365 Online</strong> or <strong>On-Premises Installation</strong> / <strong>Hosted</strong> CRM instance (IFD &#8211; internet facing deployment). You can read data from Dynamics CRM / Dataverse using SSIS connector and then exports to other sources (e.g. SQL Server, Oracle or Flat File).</p>
<p>In this new article, we will show how to connect and download the Dynamics CRM / Dataverse 365 (Online) data using <a href="https://zappysys.com/products/ssis-powerpack/ssis-dynamics-crm-source-connector/" target="_blank" rel="noopener">Dynamics CRM / Dataverse Source Connector</a>, how to query CRM data using <strong>FetchXML</strong> in SSIS and how to use variables in CRM FetchXML Query.</p>
<p>&nbsp;</p>
<h2>Requirements for SSIS Dynamics CRM / Dataverse (Dynamics 365 / On-Premises CRM / PowerApp) read component</h2>
<ol>
<li>First, you will need SSDT installed</li>
<li>Second, You will need to install <a href="https://zappysys.com/products/ssis-powerpack/" target="_blank" rel="noopener">ZappySys SSIS PowerPack</a> which includes an SSIS Dynamics CRM / Dataverse Source (Dynamics 365 / On-Premises CRM / PowerApp) task.</li>
<li>Finally, a Microsoft Dynamics account</li>
</ol>
<h2>SSIS Dynamics CRM / Dataverse Source &#8211; Video Tutorial</h2>
[youtube https://www.youtube.com/watch?v=zl0ecdjuLGk?rel=0&amp;showinfo=0&amp;w=560&amp;h=315]
<h2>Getting started with SSIS Dynamics CRM / Dataverse read component</h2>
<h3>Register Dynamics CRM / Dataverse App obtain App Id / Client Secret</h3>
<p>The very first step to access Microsoft Dynamics CRM / Dataverse 365 API is to obtain Application Id (also referred as Client Id)  and Client Secret. We will use this information later in this article (on OAuth connection UI).<br />
<a href="https://zappysys.com/blog/register-app-dynamics-crm-365-cds-dataverse-api-azure-ad-oauth/" target="_blank" rel="noopener">Register Dynamics CRM / Dataverse App With Azure</a> and get the credential (App Id, Client Secret).</p>
<h3>Configure Dynamics CRM / Dataverse Connection</h3>
<ol>
<li>
        In the connection manager, press the new button to create a new connection:</p>
<p>        <div id="attachment_3560" style="width: 756px" class="wp-caption aligncenter"><a href="https://zappysys.com/blog/wp-content/uploads/2018/05/create-a-new-connection.jpg"><img loading="lazy" decoding="async" aria-describedby="caption-attachment-3560" class="size-full wp-image-3560" src="https://zappysys.com/blog/wp-content/uploads/2018/05/create-a-new-connection.jpg" alt="SSIS create a new connection CRM Dynamics" width="746" height="403" srcset="https://zappysys.com/blog/wp-content/uploads/2018/05/create-a-new-connection.jpg 746w, https://zappysys.com/blog/wp-content/uploads/2018/05/create-a-new-connection-300x162.jpg 300w" sizes="(max-width: 746px) 100vw, 746px" /></a><p id="caption-attachment-3560" class="wp-caption-text">SSIS create a new connection CRM Dynamics</p></div>
    </li>
<li>
        Select the ZS-DYNAMICS-CRM Connection.  We will use a CRM Online connection, username, password, and organization:<br />
        <div class="su-note"  style="border-color:#e5de9d;border-radius:3px;-moz-border-radius:3px;-webkit-border-radius:3px;"><div class="su-note-inner su-u-clearfix su-u-trim" style="background-color:#fff8b7;border-color:#ffffff;color:#333333;border-radius:3px;-moz-border-radius:3px;-webkit-border-radius:3px;">NOTE: Please check the Discovery and ORG Service URL are the same as your organization URL. And if you are using Customize URL make sure that you are using it in both Discovery URL as well as in ORG Service URL also.</div></div>
<p>        <div id="attachment_3559" style="width: 775px" class="wp-caption aligncenter"><a href="https://zappysys.com/blog/wp-content/uploads/2021/11/dyanamics-crm-connection-using-oauth-clientid-connect-dataverse-api.png"><img loading="lazy" decoding="async" aria-describedby="caption-attachment-3559" class="size-full wp-image-3559" src="https://zappysys.com/blog/wp-content/uploads/2021/11/dyanamics-crm-connection-using-oauth-clientid-connect-dataverse-api.png" alt="SSIS Dynamics CRM / Dataverse credentials" width="765" height="633" /></a><p id="caption-attachment-3559" class="wp-caption-text">SSIS Dynamics CRM / Dataverse credentials</p></div>
    </li>
</ol>
<h3>How to create a Dynamics CRM / Dataverse Source</h3>
<ol>
<li>In the control flow, drag and drop the data flow:<img loading="lazy" decoding="async" class="alignnone size-full" src="https://zappysys.com/onlinehelp/ssis-powerpack/scr/images/drag-and-drop-data-flow-task.png" width="460" height="155" /></li>
<li>
        Drag and drop the ZS Dynamics CRM / Dataverse Source:</p>
<p>        <div id="attachment_3510" style="width: 653px" class="wp-caption aligncenter"><a href="https://zappysys.com/blog/wp-content/uploads/2018/05/ssis-dynamics-crm-source.jpg"><img loading="lazy" decoding="async" aria-describedby="caption-attachment-3510" class="size-full wp-image-3510" src="https://zappysys.com/blog/wp-content/uploads/2018/05/ssis-dynamics-crm-source.jpg" alt="ssis Dynamics CRM / Dataverse source" width="643" height="392" srcset="https://zappysys.com/blog/wp-content/uploads/2018/05/ssis-dynamics-crm-source.jpg 643w, https://zappysys.com/blog/wp-content/uploads/2018/05/ssis-dynamics-crm-source-300x183.jpg 300w" sizes="(max-width: 643px) 100vw, 643px" /></a><p id="caption-attachment-3510" class="wp-caption-text">SSIS Dynamics CRM / Dataverse source</p></div>
    </li>
<li>
        Second, select the connection created before and select the account table:</p>
<div id="attachment_3509" style="width: 896px" class="wp-caption aligncenter"><a href="https://zappysys.com/blog/wp-content/uploads/2018/05/ssis-entity-table-account.jpg"><img loading="lazy" decoding="async" aria-describedby="caption-attachment-3509" class="size-full wp-image-3509" src="https://zappysys.com/blog/wp-content/uploads/2018/05/ssis-entity-table-account.jpg" alt="ssis entity table account" width="886" height="603" srcset="https://zappysys.com/blog/wp-content/uploads/2018/05/ssis-entity-table-account.jpg 886w, https://zappysys.com/blog/wp-content/uploads/2018/05/ssis-entity-table-account-300x204.jpg 300w, https://zappysys.com/blog/wp-content/uploads/2018/05/ssis-entity-table-account-768x523.jpg 768w" sizes="(max-width: 886px) 100vw, 886px" /></a><p id="caption-attachment-3509" class="wp-caption-text">SSIS entity table account</p></div>
<p>        &nbsp;
    </li>
</ol>
<h3>Configure SQL Server Destination</h3>
<p>In the following example, we will show how to export the data from the account entity to SQL Server.</p>
<ol>
<li>
        First, drag and drop the OLEDB Destination and join with our ZS CRM Dynamics source:</p>
<p>        <div id="attachment_3516" style="width: 334px" class="wp-caption aligncenter"><a href="https://zappysys.com/blog/wp-content/uploads/2018/05/ssis-source-dynamics-sql-destination.jpg"><img loading="lazy" decoding="async" aria-describedby="caption-attachment-3516" class="size-full wp-image-3516" src="https://zappysys.com/blog/wp-content/uploads/2018/05/ssis-source-dynamics-sql-destination.jpg" alt="ssis source dynamics sql destination" width="324" height="202" srcset="https://zappysys.com/blog/wp-content/uploads/2018/05/ssis-source-dynamics-sql-destination.jpg 324w, https://zappysys.com/blog/wp-content/uploads/2018/05/ssis-source-dynamics-sql-destination-300x187.jpg 300w" sizes="(max-width: 324px) 100vw, 324px" /></a><p id="caption-attachment-3516" class="wp-caption-text">SSIS source dynamics SQL destination</p></div>
    </li>
<li>
        Make sure to select the account table from Dynamics:</p>
<p>        <div id="attachment_3517" style="width: 896px" class="wp-caption aligncenter"><a href="https://zappysys.com/blog/wp-content/uploads/2018/05/ssis-entity-table-account-1.jpg"><img loading="lazy" decoding="async" aria-describedby="caption-attachment-3517" class="size-full wp-image-3517" src="https://zappysys.com/blog/wp-content/uploads/2018/05/ssis-entity-table-account-1.jpg" alt="ssis entity table account" width="886" height="603" srcset="https://zappysys.com/blog/wp-content/uploads/2018/05/ssis-entity-table-account-1.jpg 886w, https://zappysys.com/blog/wp-content/uploads/2018/05/ssis-entity-table-account-1-300x204.jpg 300w, https://zappysys.com/blog/wp-content/uploads/2018/05/ssis-entity-table-account-1-768x523.jpg 768w" sizes="(max-width: 886px) 100vw, 886px" /></a><p id="caption-attachment-3517" class="wp-caption-text">SSIS Dynamics CRM / Dataverse read entity table account</p></div>
    </li>
<li>
        In addition, select an SQL Server and a database. In the name of the table, we will create a table with the following columns:<br />
<pre class="crayon-plain-tag">CREATE TABLE [crm dynamics] (
[accountcategorycode] nvarchar(255),

[accountid] uniqueidentifier,
[accountnumber] nvarchar(20),
[accountratingcode] nvarchar(255),
[accountratingcodename] nvarchar(255),
[address1_addressid] uniqueidentifier,
[address1_city] nvarchar(80),

)</pre>
        <div id="attachment_3548" style="width: 834px" class="wp-caption aligncenter"><a href="https://zappysys.com/blog/wp-content/uploads/2018/05/ssis-oledb.jpg"><img loading="lazy" decoding="async" aria-describedby="caption-attachment-3548" class="size-full wp-image-3548" src="https://zappysys.com/blog/wp-content/uploads/2018/05/ssis-oledb.jpg" alt="ssis oledb sql server" width="824" height="719" srcset="https://zappysys.com/blog/wp-content/uploads/2018/05/ssis-oledb.jpg 824w, https://zappysys.com/blog/wp-content/uploads/2018/05/ssis-oledb-300x262.jpg 300w, https://zappysys.com/blog/wp-content/uploads/2018/05/ssis-oledb-768x670.jpg 768w" sizes="(max-width: 824px) 100vw, 824px" /></a><p id="caption-attachment-3548" class="wp-caption-text">SSIS OLEBD SQL Server</p></div>
    </li>
<li>
        Go to the mapping page to map all the source and destination columns:</p>
<p>        <div id="attachment_3518" style="width: 834px" class="wp-caption aligncenter"><a href="https://zappysys.com/blog/wp-content/uploads/2018/05/dynamics-import-data.jpg"><img loading="lazy" decoding="async" aria-describedby="caption-attachment-3518" class="wp-image-3518 size-full" src="https://zappysys.com/blog/wp-content/uploads/2018/05/dynamics-import-data.jpg" alt="dynamics import data SSIS Dynamics CRM / Dataverse read" width="824" height="663" srcset="https://zappysys.com/blog/wp-content/uploads/2018/05/dynamics-import-data.jpg 824w, https://zappysys.com/blog/wp-content/uploads/2018/05/dynamics-import-data-300x241.jpg 300w, https://zappysys.com/blog/wp-content/uploads/2018/05/dynamics-import-data-768x618.jpg 768w" sizes="(max-width: 824px) 100vw, 824px" /></a><p id="caption-attachment-3518" class="wp-caption-text">SSIS Dynamics CRM / Dataverse read mapping</p></div>
    </li>
</ol>
<h3>Load Dynamics CRM / Dataverse Data to SQL Server</h3>
<ol>
<li>
        Execute the package:</p>
<p>        <div id="attachment_3563" style="width: 703px" class="wp-caption aligncenter"><a href="https://zappysys.com/blog/wp-content/uploads/2018/05/ssis-start-package.jpg"><img loading="lazy" decoding="async" aria-describedby="caption-attachment-3563" class="size-full wp-image-3563" src="https://zappysys.com/blog/wp-content/uploads/2018/05/ssis-start-package.jpg" alt="ssis start package" width="693" height="79" srcset="https://zappysys.com/blog/wp-content/uploads/2018/05/ssis-start-package.jpg 693w, https://zappysys.com/blog/wp-content/uploads/2018/05/ssis-start-package-300x34.jpg 300w" sizes="(max-width: 693px) 100vw, 693px" /></a><p id="caption-attachment-3563" class="wp-caption-text">SSIS start package</p></div>
    </li>
<li>Finally, you can see the data exported in SQL Server. Select the data from the CRM Dynamics table:</li>
</ol>
<div id="attachment_3519" style="width: 661px" class="wp-caption aligncenter"><a href="https://zappysys.com/blog/wp-content/uploads/2018/05/ssis-results.jpg"><img loading="lazy" decoding="async" aria-describedby="caption-attachment-3519" class="size-full wp-image-3519" src="https://zappysys.com/blog/wp-content/uploads/2018/05/ssis-results.jpg" alt="Data exported from crm to sql server" width="651" height="275" srcset="https://zappysys.com/blog/wp-content/uploads/2018/05/ssis-results.jpg 651w, https://zappysys.com/blog/wp-content/uploads/2018/05/ssis-results-300x127.jpg 300w" sizes="(max-width: 651px) 100vw, 651px" /></a><p id="caption-attachment-3519" class="wp-caption-text">Data exported from SSIS Dynamic CRM read</p></div>
<h2>How to query Dynamics CRM / Dataverse</h2>
<p>You can query Dynamics CRM / Dataverse data in two modes (Table mode or Query Mode). To use query mode you have to use a special language called <a href="https://msdn.microsoft.com/en-us/library/gg328332.aspx" target="_blank" rel="noopener">FetchXML</a> (sorry no SQL support).  FetchXML is an XML based query language which can be used to SELECT, FILTER, Aggregate, Transform data from CRM. Not all features from traditional SQL Language Found in FetchXML but basic query features can be implemented by writing FetchXML. Here is an example of typical FetchXML.</p><pre class="crayon-plain-tag">&lt;fetch mapping="logical" version="1.0"&gt;
  &lt;entity name="account"&gt;
    &lt;attribute name="accountid" /&gt;
    &lt;attribute name="name" /&gt;
    &lt;attribute name="country" /&gt;
    &lt;filter&gt;
      &lt;condition attribute="country" operator="in"&gt;
        &lt;value&gt;USA&lt;/value&gt;
        &lt;value&gt;UK&lt;/value&gt;
        &lt;value&gt;INDIA&lt;/value&gt;
      &lt;/condition&gt;
      &lt;condition attribute="status" operator="like" value="ACT%" /&gt;
    &lt;/filter&gt;
  &lt;/entity&gt;
&lt;/fetch&gt;</pre><p>
Above FetchXML query is equivalent to below SQL query in traditional RDBMS.</p><pre class="crayon-plain-tag">SELECT accountid,name,country 
FROM account
WHERE country IN ('USA','UK','INDIA') 
AND status LIKE 'ACT%'</pre><p>
&nbsp;</p>
<p>Now let&#8217;s look at how to build FetchXML queries by UI or by Hand.</p>
<p>&nbsp;</p>
<h3>How to generate a FetchXML query using UI</h3>
<ol>
<li>
        The Dynamics CRM / Dataverse portal contains an option to create queries visually that can be exported to XML. To do that use the <strong>Advanced Find</strong> option in the portal:</p>
<p>        <div id="attachment_3564" style="width: 1370px" class="wp-caption aligncenter"><a href="https://zappysys.com/blog/wp-content/uploads/2018/05/dynamics-crm-fetch-xml.jpg"><img loading="lazy" decoding="async" aria-describedby="caption-attachment-3564" class="size-full wp-image-3564" src="https://zappysys.com/blog/wp-content/uploads/2018/05/dynamics-crm-fetch-xml.jpg" alt="Dynamics CRM / Dataverse fetch xml" width="1360" height="403" srcset="https://zappysys.com/blog/wp-content/uploads/2018/05/dynamics-crm-fetch-xml.jpg 1360w, https://zappysys.com/blog/wp-content/uploads/2018/05/dynamics-crm-fetch-xml-300x89.jpg 300w, https://zappysys.com/blog/wp-content/uploads/2018/05/dynamics-crm-fetch-xml-768x228.jpg 768w, https://zappysys.com/blog/wp-content/uploads/2018/05/dynamics-crm-fetch-xml-1024x303.jpg 1024w" sizes="(max-width: 1360px) 100vw, 1360px" /></a><p id="caption-attachment-3564" class="wp-caption-text">Dynamics CRM / Dataverse fetch XML</p></div>
    </li>
<li>
        For example, we will query the Accounts entity where the account name is A. Datum:</p>
<p>        <div id="attachment_3565" style="width: 889px" class="wp-caption aligncenter"><a href="https://zappysys.com/blog/wp-content/uploads/2018/05/dynamics-365-crm-Create-a-query.jpg"><img loading="lazy" decoding="async" aria-describedby="caption-attachment-3565" class="size-full wp-image-3565" src="https://zappysys.com/blog/wp-content/uploads/2018/05/dynamics-365-crm-Create-a-query.jpg" alt="dynamics 365 crm Create a query" width="879" height="303" srcset="https://zappysys.com/blog/wp-content/uploads/2018/05/dynamics-365-crm-Create-a-query.jpg 879w, https://zappysys.com/blog/wp-content/uploads/2018/05/dynamics-365-crm-Create-a-query-300x103.jpg 300w, https://zappysys.com/blog/wp-content/uploads/2018/05/dynamics-365-crm-Create-a-query-768x265.jpg 768w" sizes="(max-width: 879px) 100vw, 879px" /></a><p id="caption-attachment-3565" class="wp-caption-text">dynamics 365 CRM Create a query</p></div>
    </li>
<li>
        Next, we can download the Fetch XML:</p>
<p>        <div id="attachment_3566" style="width: 798px" class="wp-caption aligncenter"><a href="https://zappysys.com/blog/wp-content/uploads/2018/05/dynamics-crm-xml-download.jpg"><img loading="lazy" decoding="async" aria-describedby="caption-attachment-3566" class="size-full wp-image-3566" src="https://zappysys.com/blog/wp-content/uploads/2018/05/dynamics-crm-xml-download.jpg" alt="Dynamics CRM / Dataverse xml download" width="788" height="312" srcset="https://zappysys.com/blog/wp-content/uploads/2018/05/dynamics-crm-xml-download.jpg 788w, https://zappysys.com/blog/wp-content/uploads/2018/05/dynamics-crm-xml-download-300x119.jpg 300w, https://zappysys.com/blog/wp-content/uploads/2018/05/dynamics-crm-xml-download-768x304.jpg 768w" sizes="(max-width: 788px) 100vw, 788px" /></a><p id="caption-attachment-3566" class="wp-caption-text">Dynamics CRM / Dataverse xml download</p></div>
    </li>
</ol>
<p>Let’s check some examples about fetch XML:</p>
<h3>SELECT All Columns (*)</h3>
<p>This example shows how to write a simple FetchXML query to select all columns<br />
of the account entity.</p>
<p>This FetchXML is the equivalent of below SQL</p><pre class="crayon-plain-tag">SELECT * FROM account</pre><p>
The option all-attributes show all the attributes. In this case, of the account entity.</p>
<p>To build custom FetxhXML:<br />
1. Login to your Dynamics CRM / Dataverse Portal<br />
2. Click on Advanced Find icon (Found next to the search textbox)<br />
3. Once done building query, Click on Download FetchXML icon. Copy that XML into Query editor of Dynamics CRM / Dataverse Source.</p>
<p>For more information about FetchXML query syntax check below links :<br />
<a href="https://msdn.microsoft.com/en-us/library/gg328117.aspx">https://msdn.microsoft.com/en-us/library/gg328117.aspx</a><br />
<a href="https://msdn.microsoft.com/en-us/library/gg328332.aspx">https://msdn.microsoft.com/en-us/library/gg328332.aspx</a></p>
<p>For complete syntax and validation rule for FetchXML check below XSD<br />
<a href="https://msdn.microsoft.com/en-us/library/gg309405.aspx">https://msdn.microsoft.com/en-us/library/gg309405.aspx</a></p><pre class="crayon-plain-tag">&lt;fetch mapping='logical' version='1.0'&gt;
 &lt;entity name='account'&gt;
 &lt;all-attributes /&gt;
 &lt;/entity&gt;  
 &lt;/fetch&gt;</pre><p>
<h3>SELECT Specified Columns and Alias with SSIS Dynamics CRM / Dataverse</h3>
<p>This example shows how to write a simple FetchXML query to select two columns and use an alias for column name (e.g. name is renamed to accountname).</p>
<p>This FetchXML is the equivalent of below SQL</p><pre class="crayon-plain-tag">SELECT accountid, name as accountname
FROM account</pre><p>
To build custom FetxhXML<br />
1. Login to your Dynamics CRM / Dataverse Portal<br />
2. Click on Advanced Find icon (Found next to the search textbox)<br />
3. Once done building query, Click on Download FetchXML icon. Copy that XML into Query editor of Dynamics CRM / Dataverse Source.</p>
<p>For more information about FetchXML query syntax check below links :<br />
<a href="https://msdn.microsoft.com/en-us/library/gg328117.aspx">https://msdn.microsoft.com/en-us/library/gg328117.aspx</a><br />
<a href="https://msdn.microsoft.com/en-us/library/gg328332.aspx">https://msdn.microsoft.com/en-us/library/gg328332.aspx</a></p>
<p>For complete syntax and validation rule for FetchXML check below XSD<br />
<a href="https://msdn.microsoft.com/en-us/library/gg309405.aspx">https://msdn.microsoft.com/en-us/library/gg309405.aspx</a></p><pre class="crayon-plain-tag">&lt;fetch mapping='logical'&gt; 
	&lt;entity name='account'&gt;
		&lt;attribute name='accountid'/&gt; 
		&lt;attribute name='name' alias = 'accountname'/&gt; 
	&lt;/entity&gt;
&lt;/fetch&gt;</pre><p>
<h3>WHERE (AND conditions)</h3>
<p>This example shows how to write FetchXML query to filter data using multiple conditions (AND).</p>
<p>This FetchXML is the equivalent of below SQL</p><pre class="crayon-plain-tag">SELECT * FROM account WHERE revenue &gt; 0 AND name like 'A%'</pre><p>
To build custom FetxhXML<br />
1. Login to your Dynamics CRM / Dataverse Portal<br />
2. Click on Advanced Find icon (Found next to the search textbox)<br />
3. Once done building query, Click on Download FetchXML icon. Copy that XML into Query editor of Dynamics CRM / Dataverse Source.<br />
For more information about FetchXML query syntax check below links :<br />
<a href="https://msdn.microsoft.com/en-us/library/gg328117.aspx">https://msdn.microsoft.com/en-us/library/gg328117.aspx</a><br />
<a href="https://msdn.microsoft.com/en-us/library/gg328332.aspx">https://msdn.microsoft.com/en-us/library/gg328332.aspx</a></p>
<p>For complete syntax and validation rule for FetchXML check below XSD<br />
<a href="https://msdn.microsoft.com/en-us/library/gg309405.aspx">https://msdn.microsoft.com/en-us/library/gg309405.aspx</a></p><pre class="crayon-plain-tag">&lt;fetch mapping='logical' version='1.0'&gt;
	&lt;entity name='account'&gt;
		&lt;all-attributes /&gt;
		&lt;filter&gt;
			&lt;condition attribute='revenue' operator='gt' value='0' /&gt;
			&lt;condition attribute='name' operator='like' value='A%' /&gt;
		&lt;/filter&gt;
	&lt;/entity&gt;
&lt;/fetch&gt;</pre><p>
<h3>WHERE (OR conditions)</h3>
<p>This example shows how to write FetchXML query to filter data using multiple conditions (OR).</p>
<p>This FetchXML is the equivalent of below SQL</p><pre class="crayon-plain-tag">SELECT * FROM account WHERE revenue &gt; 0 OR name like 'A%'</pre><p>
To build custom FetxhXML<br />
1. Login to your Dynamics CRM / Dataverse Portal<br />
2. Click on Advanced Find icon (Found next to the search textbox)<br />
3. Once done building query, Click on Download FetchXML icon. Copy that XML into Query editor of Dynamics CRM / Dataverse Source.<br />
For more information about FetchXML query syntax check below links :<br />
<a href="https://msdn.microsoft.com/en-us/library/gg328117.aspx">https://msdn.microsoft.com/en-us/library/gg328117.aspx</a><br />
<a href="https://msdn.microsoft.com/en-us/library/gg328332.aspx">https://msdn.microsoft.com/en-us/library/gg328332.aspx</a></p>
<p>For complete syntax and validation rule for FetchXML check below XSD<br />
<a href="https://msdn.microsoft.com/en-us/library/gg309405.aspx">https://msdn.microsoft.com/en-us/library/gg309405.aspx</a></p><pre class="crayon-plain-tag">&lt;fetch mapping='logical' version='1.0'&gt;
	&lt;entity name='account'&gt;
		&lt;all-attributes /&gt;
		&lt;filter type='or'&gt;
			&lt;condition attribute='revenue' operator='gt' value='0' /&gt;
			&lt;condition attribute='name' operator='like' value='A%' /&gt;
		&lt;/filter&gt;
	&lt;/entity&gt;
&lt;/fetch&gt;</pre><p>
<h3>WHERE (Mixing AND / OR conditions)</h3>
<p>This example shows how to write FetchXML query to filter data using multiple conditions (Mixing AND / OR).</p>
<p>This FetchXML is the equivalent of below SQL</p><pre class="crayon-plain-tag">SELECT * FROM account 
WHERE revenue &gt; 0 AND
    (
     name LIKE 'A%' OR 
     name LIKE 'B%'
    )</pre><p>
To build custom FetxhXML<br />
1. Login to your Dynamics CRM / Dataverse Portal<br />
2. Click on Advanced Find icon (Found next to the search textbox)<br />
3. Once done building query, Click on Download FetchXML icon. Copy that XML into Query editor of Dynamics CRM / Dataverse Source.<br />
For more information about FetchXML query syntax check below links :<br />
<a href="https://msdn.microsoft.com/en-us/library/gg328117.aspx">https://msdn.microsoft.com/en-us/library/gg328117.aspx</a><br />
<a href="https://msdn.microsoft.com/en-us/library/gg328332.aspx">https://msdn.microsoft.com/en-us/library/gg328332.aspx</a></p>
<p>For complete syntax and validation rule for FetchXML check below XSD<br />
<a href="https://msdn.microsoft.com/en-us/library/gg309405.aspx">https://msdn.microsoft.com/en-us/library/gg309405.aspx</a></p><pre class="crayon-plain-tag">&lt;fetch mapping='logical' version='1.0'&gt;
	&lt;entity name='account'&gt;
		&lt;all-attributes /&gt;
		&lt;filter&gt;
			&lt;condition attribute='revenue' operator='gt' value='0' /&gt;
			&lt;filter type='or'&gt;
				&lt;condition attribute='name' operator='like' value='A%' /&gt;
				&lt;condition attribute='name' operator='like' value='B%' /&gt;
			&lt;/filter&gt;
		&lt;/filter&gt;
	&lt;/entity&gt;
&lt;/fetch&gt;</pre><p>
<h3>SELECT DISTINCT (Exclude duplicates)</h3>
<p>This example shows how to write FetchXML query to get distinct records (exclude duplicates).</p>
<p>This FetchXML is the equivalent of below SQL</p><pre class="crayon-plain-tag">SELECT DISTINCT accountid,name FROM account</pre><p>
To build custom FetxhXML<br />
1. Login to your Dynamics CRM / Dataverse Portal<br />
2. Click on Advanced Find icon (Found next to the search textbox)<br />
3. Once done building query, Click on Download FetchXML icon. Copy that XML into Query editor of Dynamics CRM / Dataverse Source.</p>
<p>For more information about FetchXML query syntax check below links:<br />
<a href="https://msdn.microsoft.com/en-us/library/gg328117.aspx">https://msdn.microsoft.com/en-us/library/gg328117.aspx</a><br />
<a href="https://msdn.microsoft.com/en-us/library/gg328332.aspx">https://msdn.microsoft.com/en-us/library/gg328332.aspx</a></p>
<p>For complete syntax and validation rule for FetchXML check below XSD<br />
<a href="https://msdn.microsoft.com/en-us/library/gg309405.aspx">https://msdn.microsoft.com/en-us/library/gg309405.aspx</a></p><pre class="crayon-plain-tag">&lt;fetch mapping='logical' distinct='true' version='1.0'&gt;
	&lt;entity name='account'&gt; 
		&lt;attribute name='accountid' /&gt;
		&lt;attribute name='name' /&gt;
	&lt;/entity&gt;
&lt;/fetch&gt;</pre><p>
<h3>SELECT TOP using SSIS Dynamics CRM / Dataverse read</h3>
<p>This example shows how to write FetchXML query to select TOP N rows. This setting may not work if you using preview mode.</p>
<p>This FetchXML is the equivalent of below SQL</p><pre class="crayon-plain-tag">SELECT TOP 10 * FROM account</pre><p>
To build custom FetxhXML<br />
1. Login to your Dynamics CRM / Dataverse Portal<br />
2. Click on Advanced Find icon (Found next to the search textbox)<br />
3. Once done building query, Click on Download FetchXML icon. Copy that XML into Query editor of Dynamics CRM / Dataverse Source.</p>
<p>For more information about FetchXML query syntax check below links :<br />
<a href="https://msdn.microsoft.com/en-us/library/gg328117.aspx">https://msdn.microsoft.com/en-us/library/gg328117.aspx</a><br />
<a href="https://msdn.microsoft.com/en-us/library/gg328332.aspx">https://msdn.microsoft.com/en-us/library/gg328332.aspx</a></p>
<p>For complete syntax and validation rule for FetchXML check below XSD<br />
<a href="https://msdn.microsoft.com/en-us/library/gg309405.aspx">https://msdn.microsoft.com/en-us/library/gg309405.aspx</a></p><pre class="crayon-plain-tag">&lt;fetch mapping='logical' count='10' version='1.0'&gt;
  &lt;entity name='account'&gt;
    &lt;all-attributes /&gt;
  &lt;/entity&gt;
&lt;/fetch&gt;</pre><p>
<h3>GROUP BY / Aggregate functions</h3>
<p>This example shows how to use aggregate functions such as SUM, MIN, MAX, AVG along with GROUP BY clause. When you use the Aggregate function in SQL Query you can also use an alias for the field. Refer FetchXML help to learn more about aggregate functions.</p>
<p>This FetchXML is the equivalent of below SQL</p><pre class="crayon-plain-tag">SELECT AVG(estimatedvalue) AS estimatedvalue_avg, COUNT(name) AS opportunity_count, ownerid AS ownerid
FROM opportunity 
GROUP BY ownerid</pre><p>
You can use COUNT, COUNT(attribute_name), SUM, MIN, MAX, AVG as an aggregate function</p>
<p>To build custom FetxhXML<br />
1. Login to your Dynamics CRM / Dataverse Portal<br />
2. Click on Advanced Find icon (Found next to the search textbox)<br />
3. Once done building query, Click on Download FetchXML icon. Copy that XML into Query editor of Dynamics CRM / Dataverse Source.</p>
<p>For more information about FetchXML query syntax check below links :<br />
<a href="https://msdn.microsoft.com/en-us/library/gg328117.aspx">https://msdn.microsoft.com/en-us/library/gg328117.aspx</a><br />
<a href="https://msdn.microsoft.com/en-us/library/gg328332.aspx">https://msdn.microsoft.com/en-us/library/gg328332.aspx</a></p>
<p>For complete syntax and validation rule for FetchXML check below XSD<br />
<a href="https://msdn.microsoft.com/en-us/library/gg309405.aspx">https://msdn.microsoft.com/en-us/library/gg309405.aspx</a></p><pre class="crayon-plain-tag">&lt;fetch distinct='false' mapping='logical' aggregate='true'&gt; 
    &lt;entity name='opportunity'&gt; 
       &lt;attribute name='estimatedvalue' aggregate='avg' alias='estimatedvalue_avg'  /&gt; 
       &lt;attribute name='name' aggregate='countcolumn' alias='opportunity_count' /&gt; 
       &lt;attribute name='ownerid' alias='ownerid' groupby='true' /&gt; 
    &lt;/entity&gt; 
&lt;/fetch&gt;</pre><p>
<h3>INNER JOIN (matching child records)</h3>
<p>This example shows how to write FetchXML query to get account and associated contacts where email is @gmail.com or yahoo.com or hotmail.com and revenue for account is &gt; 10000.</p>
<p>This FetchXML is the equivalent of below SQL</p><pre class="crayon-plain-tag">SELECT a.name, c.firstname, c.lastname, c.email
FROM account a
INNER JOIN contact c ON a.accountid=c.parentcustomerid
                     AND (c.email LIKE '%@yahoo.com'
                          OR c.email LIKE '%@gmail.com'
                          OR c.email LIKE '%@hotmail.com')
WHERE a.revenue &gt; 10000</pre><p>
To build custom FetxhXML<br />
1. Login to your Dynamics CRM / Dataverse Portal<br />
2. Click on Advanced Find icon (Found next to the search textbox)<br />
3. Once done building query, Click on Download FetchXML icon. Copy that XML into Query editor of Dynamics CRM / Dataverse Source.</p>
<p>For more information about FetchXML query syntax check below links :<br />
<a href="https://msdn.microsoft.com/en-us/library/gg328117.aspx">https://msdn.microsoft.com/en-us/library/gg328117.aspx</a><br />
<a href="https://msdn.microsoft.com/en-us/library/gg328332.aspx">https://msdn.microsoft.com/en-us/library/gg328332.aspx</a></p>
<p>For complete syntax and validation rule for FetchXML check below XSD<br />
<a href="https://msdn.microsoft.com/en-us/library/gg309405.aspx">https://msdn.microsoft.com/en-us/library/gg309405.aspx</a></p><pre class="crayon-plain-tag">&lt;fetch mapping='logical' version='1.0'&gt;
  &lt;entity name='account'&gt;
    &lt;attribute name='name' /&gt;
    &lt;filter&gt;
      &lt;condition attribute='revenue' operator='gt' value='10000' /&gt;
    &lt;/filter&gt;
    &lt;link-entity name='contact' from='parentcustomerid' to='accountid' alias='c' link-type='inner'&gt;
      &lt;attribute name='firstname' /&gt;
      &lt;attribute name='lastname' /&gt;
      &lt;attribute name='email' /&gt;
      &lt;filter type='or'&gt;
        &lt;condition attribute='email' operator='like' value='%@yahoo.com' /&gt;
        &lt;filter type='or'&gt;
          &lt;condition attribute='email' operator='like' value='%@gmail.com' /&gt;
          &lt;condition attribute='email' operator='like' value='%@hotmail.com' /&gt;
        &lt;/filter&gt;
      &lt;/filter&gt;
    &lt;/link-entity&gt;
  &lt;/entity&gt;
&lt;/fetch&gt;</pre><p>
<h3>LEFT OUTER JOIN (&#8216;not in&#8217; type query)</h3>
<p>This example shows how to write FetchXML query to find all leads that have no tasks, using an alias.</p>
<p>This FetchXML is the equivalent of below SQL</p><pre class="crayon-plain-tag">SELECT lead.FullName
FROM Leads as lead
LEFT OUTER JOIN Tasks as ab
    ON (lead.leadId  =  ab.RegardingObjectId)
WHERE ab.RegardingObjectId is null</pre><p>
For more information on left outer join syntax check below link<br />
<a href="https://msdn.microsoft.com/en-us/library/dn531006.aspx">https://msdn.microsoft.com/en-us/library/dn531006.aspx</a></p>
<p>To build custom FetxhXML<br />
1. Login to your Dynamics CRM / Dataverse Portal<br />
2. Click on Advanced Find icon (Found next to the search textbox)<br />
3. Once done building query, Click on Download FetchXML icon. Copy that XML into Query editor of Dynamics CRM / Dataverse Source.</p>
<p>For more information about FetchXML query syntax check below links :<br />
<a href="https://msdn.microsoft.com/en-us/library/gg328117.aspx">https://msdn.microsoft.com/en-us/library/gg328117.aspx</a><br />
<a href="https://msdn.microsoft.com/en-us/library/gg328332.aspx">https://msdn.microsoft.com/en-us/library/gg328332.aspx</a></p>
<p>For complete syntax and validation rule for FetchXML check below XSD<br />
<a href="https://msdn.microsoft.com/en-us/library/gg309405.aspx">https://msdn.microsoft.com/en-us/library/gg309405.aspx</a></p><pre class="crayon-plain-tag">&lt;fetch version='1.0' output-format='xml-platform' mapping='logical' distinct='true'&gt;
  &lt;entity name='lead'&gt;
    &lt;attribute name='fullname' /&gt;
    &lt;link-entity name='task' from='regardingobjectid' to='leadid' alias='ab' link-type='outer'&gt;
       &lt;attribute name='regardingobjectid' /&gt;
    &lt;/link-entity&gt;
    &lt;filter type='and'&gt;
        &lt;condition entityname='ab' attribute='regardingobjectid' operator='null' /&gt;
    &lt;/filter&gt;
  &lt;/entity&gt;
&lt;fetch/&gt;</pre><p>
<h3>ORDER BY</h3>
<p>This example shows how to write FetchXML query with order by specified for one or more attributes.</p>
<p>This FetchXML is the equivalent of below SQL</p><pre class="crayon-plain-tag">SELECT firstname, lastname, email FROM contact
ORDER BY lastname ASC, firstname DESC</pre><p>
To build custom FetxhXML<br />
1. Login to your Dynamics CRM / Dataverse Portal<br />
2. Click on Advanced Find icon (Found next to the search textbox)<br />
3. Once done building query, Click on Download FetchXML icon. Copy that XML into Query editor of Dynamics CRM / Dataverse Source.</p>
<p>For more information about FetchXML query syntax check below links :<br />
<a href="https://msdn.microsoft.com/en-us/library/gg328117.aspx">https://msdn.microsoft.com/en-us/library/gg328117.aspx</a><br />
<a href="https://msdn.microsoft.com/en-us/library/gg328332.aspx">https://msdn.microsoft.com/en-us/library/gg328332.aspx</a></p>
<p>For complete syntax and validation rule for FetchXML check below XSD<br />
<a href="https://msdn.microsoft.com/en-us/library/gg309405.aspx">https://msdn.microsoft.com/en-us/library/gg309405.aspx</a></p><pre class="crayon-plain-tag">&lt;fetch mapping='logical' version='1.0'&gt;
  &lt;entity name='contact'&gt;
    &lt;attribute name='firstname' /&gt;
    &lt;attribute name='lastname' /&gt;
    &lt;attribute name='email' /&gt;
    &lt;order attribute='lastname' /&gt;
    &lt;order attribute='firstname' descending='true' /&gt;
  &lt;/entity&gt;
&lt;/fetch&gt;</pre><p>
<h3>OPERATOR &#8211; Equal ( = )</h3>
<p>This example shows how to write FetchXML query using equal operator.</p>
<p>This FetchXML is the equivalent of below SQL</p><pre class="crayon-plain-tag">SELECT name FROM account WHERE revenue=0</pre><p>
For a list of supported operators check below XSD and search for name=&#8221;operator&#8221;<br />
<a href="https://msdn.microsoft.com/en-us/library/gg309405.aspx">https://msdn.microsoft.com/en-us/library/gg309405.aspx</a></p>
<p>To build custom FetxhXML<br />
1. Login to your Dynamics CRM / Dataverse Portal<br />
2. Click on Advanced Find icon (Found next to the search textbox)<br />
3. Once done building query, Click on Download FetchXML icon. Copy that XML into Query editor of Dynamics CRM / Dataverse Source.</p>
<p>For more information about FetchXML query syntax check below links :<br />
<a href="https://msdn.microsoft.com/en-us/library/gg328117.aspx">https://msdn.microsoft.com/en-us/library/gg328117.aspx</a><br />
<a href="https://msdn.microsoft.com/en-us/library/gg328332.aspx">https://msdn.microsoft.com/en-us/library/gg328332.aspx</a></p>
<p>For complete syntax and validation rule for FetchXML check below XSD<br />
<a href="https://msdn.microsoft.com/en-us/library/gg309405.aspx">https://msdn.microsoft.com/en-us/library/gg309405.aspx</a></p><pre class="crayon-plain-tag">&lt;fetch mapping='logical' version='1.0'&gt;
  &lt;entity name='account'&gt;
    &lt;attribute name='name' /&gt;
    &lt;filter&gt;
      &lt;condition attribute='revenue' operator='eq' value='0' /&gt;
    &lt;/filter&gt;
  &lt;/entity&gt;
&lt;/fetch</pre><p>
<h3>OPERATOR &#8211; Not Equal ( != )</h3>
<p>This example shows how to write FetchXML query using not equal operator.</p>
<p>This FetchXML is the equivalent of below SQL</p><pre class="crayon-plain-tag">SELECT name FROM account WHERE revenue != 0</pre><p>
For a list of supported operators check below XSD and search for name=&#8221;operator&#8221;<br />
<a href="https://msdn.microsoft.com/en-us/library/gg309405.aspx">https://msdn.microsoft.com/en-us/library/gg309405.aspx</a></p>
<p>To build custom FetxhXML<br />
1. Login to your Dynamics CRM / Dataverse Portal<br />
2. Click on Advanced Find icon (Found next to the search textbox)<br />
3. Once done building query, Click on Download FetchXML icon. Copy that XML into Query editor of Dynamics CRM / Dataverse Source.</p>
<p>For more information about FetchXML query syntax check below links :<br />
<a href="https://msdn.microsoft.com/en-us/library/gg328117.aspx">https://msdn.microsoft.com/en-us/library/gg328117.aspx</a><br />
<a href="https://msdn.microsoft.com/en-us/library/gg328332.aspx">https://msdn.microsoft.com/en-us/library/gg328332.aspx</a></p>
<p>For complete syntax and validation rule for FetchXML check below XSD<br />
<a href="https://msdn.microsoft.com/en-us/library/gg309405.aspx">https://msdn.microsoft.com/en-us/library/gg309405.aspx</a></p><pre class="crayon-plain-tag">&lt;fetch mapping='logical' version='1.0'&gt;
  &lt;entity name='account'&gt;
    &lt;attribute name='name' /&gt;
    &lt;filter&gt;
      &lt;condition attribute='revenue' operator='ne' value='0' /&gt;
    &lt;/filter&gt;
  &lt;/entity&gt;
&lt;/fetch&gt;</pre><p>
<h3>OPERATOR &#8211; Greater Than ( &gt; )</h3>
<p>This example shows how to write FetchXML query using greater than the operator.</p>
<p>This FetchXML is the equivalent of below SQL</p><pre class="crayon-plain-tag">SELECT name FROM account WHERE revenue &gt; 0</pre><p>
For a list of supported operators check below XSD and search for name=&#8221;operator&#8221;<br />
<a href="https://msdn.microsoft.com/en-us/library/gg309405.aspx">https://msdn.microsoft.com/en-us/library/gg309405.aspx</a></p>
<p>To build custom FetxhXML<br />
1. Login to your Dynamics CRM / Dataverse Portal<br />
2. Click on Advanced Find icon (Found next to the search textbox)<br />
3. Once done building query, Click on Download FetchXML icon. Copy that XML into Query editor of Dynamics CRM / Dataverse Source.</p>
<p>For more information about FetchXML query syntax check below links :<br />
<a href="https://msdn.microsoft.com/en-us/library/gg328117.aspx">https://msdn.microsoft.com/en-us/library/gg328117.aspx</a><br />
<a href="https://msdn.microsoft.com/en-us/library/gg328332.aspx">https://msdn.microsoft.com/en-us/library/gg328332.aspx</a></p>
<p>For complete syntax and validation rule for FetchXML check below XSD<br />
<a href="https://msdn.microsoft.com/en-us/library/gg309405.aspx">https://msdn.microsoft.com/en-us/library/gg309405.aspx</a></p><pre class="crayon-plain-tag">&lt;fetch mapping='logical' version='1.0'&gt;
  &lt;entity name='account'&gt;
    &lt;attribute name='name' /&gt;
    &lt;filter&gt;
      &lt;condition attribute='revenue' operator='gt' value='0' /&gt;
    &lt;/filter&gt;
  &lt;/entity&gt;
&lt;/fetch&gt;</pre><p>
<h3>OPERATOR &#8211; Less Than ( &lt; )</h3>
<p>This example shows how to write FetchXML query using greater than the operator.</p>
<p>This FetchXML is the equivalent of below SQL</p><pre class="crayon-plain-tag">SELECT name FROM account WHERE revenue &lt; 0</pre><p>
For a list of supported operators check below XSD and search for name=&#8221;operator&#8221;<br />
<a href="https://msdn.microsoft.com/en-us/library/gg309405.aspx">https://msdn.microsoft.com/en-us/library/gg309405.aspx</a></p>
<p>To build custom FetxhXML<br />
1. Login to your Dynamics CRM / Dataverse Portal<br />
2. Click on Advanced Find icon (Found next to the search textbox)<br />
3. Once done building query, Click on Download FetchXML icon. Copy that XML into Query editor of Dynamics CRM / Dataverse Source.</p>
<p>For more information about FetchXML query syntax check below links :<br />
<a href="https://msdn.microsoft.com/en-us/library/gg328117.aspx">https://msdn.microsoft.com/en-us/library/gg328117.aspx</a><br />
<a href="https://msdn.microsoft.com/en-us/library/gg328332.aspx">https://msdn.microsoft.com/en-us/library/gg328332.aspx</a></p>
<p>For complete syntax and validation rule for FetchXML check below XSD<br />
<a href="https://msdn.microsoft.com/en-us/library/gg309405.aspx">https://msdn.microsoft.com/en-us/library/gg309405.aspx</a></p><pre class="crayon-plain-tag">&lt;fetch mapping='logical' version='1.0'&gt;
  &lt;entity name='account'&gt;
    &lt;attribute name='name' /&gt;
    &lt;filter&gt;
      &lt;condition attribute='revenue' operator='lt' value='0' /&gt;
    &lt;/filter&gt;
  &lt;/entity&gt;
&lt;/fetch&gt;</pre><p>
<h3>OPERATOR &#8211; IN (Check for multiple matching values)</h3>
<p>This example shows how to write FetchXML query to find multiple matching values using IN operator.</p>
<p>This FetchXML is the equivalent of below SQL</p><pre class="crayon-plain-tag">SELECT name FROM account WHERE name IN ('Microsoft', 'Yahoo', 'Google')</pre><p>
For a list of supported operators check below XSD and search for name=&#8221;operator&#8221;<br />
<a href="https://msdn.microsoft.com/en-us/library/gg309405.aspx">https://msdn.microsoft.com/en-us/library/gg309405.aspx</a></p>
<p>To build custom FetxhXML<br />
1. Login to your Dynamics CRM / Dataverse Portal<br />
2. Click on Advanced Find icon (Found next to the search textbox)<br />
3. Once done building query, Click on Download FetchXML icon. Copy that XML into Query editor of Dynamics CRM / Dataverse Source.</p>
<p>For more information about FetchXML query syntax check below links :<br />
<a href="https://msdn.microsoft.com/en-us/library/gg328117.aspx">https://msdn.microsoft.com/en-us/library/gg328117.aspx</a><br />
<a href="https://msdn.microsoft.com/en-us/library/gg328332.aspx">https://msdn.microsoft.com/en-us/library/gg328332.aspx</a></p>
<p>For complete syntax and validation rule for FetchXML check below XSD<br />
<a href="https://msdn.microsoft.com/en-us/library/gg309405.aspx">https://msdn.microsoft.com/en-us/library/gg309405.aspx</a></p><pre class="crayon-plain-tag">&lt;fetch mapping='logical' version='1.0'&gt;
  &lt;entity name='account'&gt;
    &lt;attribute name='name' /&gt;
    &lt;filter&gt;
      &lt;condition attribute='name' operator='in'&gt;
        &lt;value&gt;Microsoft&lt;/value&gt;
        &lt;value&gt;Yahoo&lt;/value&gt;
        &lt;value&gt;Google&lt;/value&gt;
      &lt;/condition&gt;
    &lt;/filter&gt;
  &lt;/entity&gt;
&lt;/fetch&gt;</pre><p>
<h3>OPERATOR &#8211; NULL (Check for NULL values)</h3>
<p>This example shows how to write FetchXML query to find NULL values (search for records where email not specified).</p>
<p>This FetchXML is the equivalent of below SQL</p><pre class="crayon-plain-tag">SELECT firstname, lastname, email FROM contact WHERE email is NULL</pre><p>
For a list of supported operators check below XSD and search for name=&#8221;operator&#8221;<br />
<a href="https://msdn.microsoft.com/en-us/library/gg309405.aspx">https://msdn.microsoft.com/en-us/library/gg309405.aspx</a></p>
<p>To build custom FetxhXML<br />
1. Login to your Dynamics CRM / Dataverse Portal<br />
2. Click on Advanced Find icon (Found next to the search textbox)<br />
3. Once done building query, Click on Download FetchXML icon. Copy that XML into Query editor of Dynamics CRM / Dataverse Source.</p>
<p>For more information about FetchXML query syntax check below links :<br />
<a href="https://msdn.microsoft.com/en-us/library/gg328117.aspx">https://msdn.microsoft.com/en-us/library/gg328117.aspx</a><br />
<a href="https://msdn.microsoft.com/en-us/library/gg328332.aspx">https://msdn.microsoft.com/en-us/library/gg328332.aspx</a></p>
<p>For complete syntax and validation rule for FetchXML check below XSD<br />
<a href="https://msdn.microsoft.com/en-us/library/gg309405.aspx">https://msdn.microsoft.com/en-us/library/gg309405.aspx</a></p><pre class="crayon-plain-tag">&lt;fetch mapping='logical' version='1.0'&gt;
  &lt;entity name='contact'&gt;
    &lt;attribute name='firstname' /&gt;
    &lt;attribute name='lastname' /&gt;
    &lt;attribute name='email' /&gt;	
    &lt;filter&gt;
      &lt;condition attribute='email' operator='null' /&gt;
    &lt;/filter&gt;
  &lt;/entity&gt;
&lt;/fetch&gt;</pre><p>
<h3>OPERATOR &#8211; NOT NULL (Check for NOT NULL values)</h3>
<p>This example shows how to write FetchXML query to find NOT NULL values (search for records where email not specified).</p>
<p>This FetchXML is the equivalent of below SQL</p><pre class="crayon-plain-tag">SELECT firstname, lastname, email FROM contact WHERE email is NOT NULL</pre><p>
For a list of supported operators check below XSD and search for name=&#8221;operator&#8221;<br />
<a href="https://msdn.microsoft.com/en-us/library/gg309405.aspx">https://msdn.microsoft.com/en-us/library/gg309405.aspx</a></p>
<p>To build custom FetxhXML<br />
1. Login to your Dynamics CRM / Dataverse Portal<br />
2. Click on Advanced Find icon (Found next to the search textbox)<br />
3. Once done building query, Click on Download FetchXML icon. Copy that XML into Query editor of Dynamics CRM / Dataverse Source.</p>
<p>For more information about FetchXML query syntax check below links :<br />
<a href="https://msdn.microsoft.com/en-us/library/gg328117.aspx">https://msdn.microsoft.com/en-us/library/gg328117.aspx</a><br />
<a href="https://msdn.microsoft.com/en-us/library/gg328332.aspx">https://msdn.microsoft.com/en-us/library/gg328332.aspx</a></p>
<p>For complete syntax and validation rule for FetchXML check below XSD<br />
<a href="https://msdn.microsoft.com/en-us/library/gg309405.aspx">https://msdn.microsoft.com/en-us/library/gg309405.aspx</a></p><pre class="crayon-plain-tag">&lt;fetch mapping='logical' version='1.0'&gt;
  &lt;entity name='contact'&gt;
    &lt;attribute name='firstname' /&gt;
    &lt;attribute name='lastname' /&gt;
    &lt;attribute name='email' /&gt;	
    &lt;filter&gt;
      &lt;condition attribute='email' operator='not-null' /&gt;
    &lt;/filter&gt;
  &lt;/entity&gt;
&lt;/fetch&gt;</pre><p>
<h3>OPERATOR &#8211; LIKE (Pattern search)</h3>
<p>This example shows how to write FetchXML query using LIKE operator to match string by pattern search.</p>
<p>This FetchXML is the equivalent of below SQL</p><pre class="crayon-plain-tag">SELECT name FROM account WHERE name LIKE 'zappy%'</pre><p>
For a list of supported operators check below XSD and search for name=&#8221;operator&#8221;<br />
<a href="https://msdn.microsoft.com/en-us/library/gg309405.aspx">https://msdn.microsoft.com/en-us/library/gg309405.aspx</a></p>
<p>To build custom FetxhXML<br />
1. Login to your Dynamics CRM / Dataverse Portal<br />
2. Click on Advanced Find icon (Found next to the search textbox)<br />
3. Once done building query, Click on Download FetchXML icon. Copy that XML into Query editor of Dynamics CRM / Dataverse Source.</p>
<p>For more information about FetchXML query syntax check below links :<br />
<a href="https://msdn.microsoft.com/en-us/library/gg328117.aspx">https://msdn.microsoft.com/en-us/library/gg328117.aspx</a><br />
<a href="https://msdn.microsoft.com/en-us/library/gg328332.aspx">https://msdn.microsoft.com/en-us/library/gg328332.aspx</a></p>
<p>For complete syntax and validation rule for FetchXML check below XSD<br />
<a href="https://msdn.microsoft.com/en-us/library/gg309405.aspx">https://msdn.microsoft.com/en-us/library/gg309405.aspx</a></p><pre class="crayon-plain-tag">&lt;fetch mapping='logical' version='1.0'&gt;
  &lt;entity name='account'&gt;
    &lt;attribute name='name' /&gt;
    &lt;filter&gt;
      &lt;condition attribute='name' operator='like' value='zappy%' /&gt;
    &lt;/filter&gt;
  &lt;/entity&gt;
&lt;/fetch&gt;</pre><p>
<h3>OPERATOR &#8211; NOT LIKE (Pattern search)</h3>
<p>This example shows how to write FetchXML query using LIKE operator to match string by pattern search.</p>
<p>This FetchXML is the equivalent of below SQL</p><pre class="crayon-plain-tag">SELECT name FROM account WHERE name NOT LIKE 'zappy%'</pre><p>
For a list of supported operators check below XSD and search for name=&#8221;operator&#8221;<br />
<a href="https://msdn.microsoft.com/en-us/library/gg309405.aspx">https://msdn.microsoft.com/en-us/library/gg309405.aspx</a></p>
<p>To build custom FetxhXML<br />
1. Login to your Dynamics CRM / Dataverse Portal<br />
2. Click on Advanced Find icon (Found next to the search textbox)<br />
3. Once done building query, Click on Download FetchXML icon. Copy that XML into Query editor of Dynamics CRM / Dataverse Source.</p>
<p>For more information about FetchXML query syntax check below links :<br />
<a href="https://msdn.microsoft.com/en-us/library/gg328117.aspx">https://msdn.microsoft.com/en-us/library/gg328117.aspx</a><br />
<a href="https://msdn.microsoft.com/en-us/library/gg328332.aspx">https://msdn.microsoft.com/en-us/library/gg328332.aspx</a></p>
<p>For complete syntax and validation rule for FetchXML check below XSD<br />
<a href="https://msdn.microsoft.com/en-us/library/gg309405.aspx">https://msdn.microsoft.com/en-us/library/gg309405.aspx</a></p><pre class="crayon-plain-tag">&lt;fetch mapping='logical' version='1.0'&gt;
  &lt;entity name='account'&gt;
    &lt;attribute name='name' /&gt;
    &lt;filter&gt;
      &lt;condition attribute='name' operator='not-like' value='zappy%' /&gt;
    &lt;/filter&gt;
  &lt;/entity&gt;
&lt;/fetch&gt;</pre><p>
<h3>OPERATOR &#8211; UNDER (Find all children for given hierarchy) with the SSIS Dynamics CRM / Dataverse read task</h3>
<p>This example shows how to write FetchXML query to get children count for a given hierarchy.</p>
<p>For more information about querying hierarchical data check below link<br />
<a href="https://msdn.microsoft.com/en-us/library/dn817893.aspx">https://msdn.microsoft.com/en-us/library/dn817893.aspx</a></p>
<p>For a list of supported operators check below XSD and search for name=&#8221;operator&#8221;<br />
<a href="https://msdn.microsoft.com/en-us/library/gg309405.aspx">https://msdn.microsoft.com/en-us/library/gg309405.aspx</a></p>
<p>To build custom FetxhXML<br />
1. Login to your Dynamics CRM / Dataverse Portal<br />
2. Click on Advanced Find icon (Found next to the search textbox)<br />
3. Once done building query, Click on Download FetchXML icon. Copy that XML into Query editor of Dynamics CRM / Dataverse Source.</p>
<p>For more information about FetchXML query syntax check below links :<br />
<a href="https://msdn.microsoft.com/en-us/library/gg328117.aspx">https://msdn.microsoft.com/en-us/library/gg328117.aspx</a><br />
<a href="https://msdn.microsoft.com/en-us/library/gg328332.aspx">https://msdn.microsoft.com/en-us/library/gg328332.aspx</a></p>
<p>For complete syntax and validation rule for FetchXML check below XSD<br />
<a href="https://msdn.microsoft.com/en-us/library/gg309405.aspx">https://msdn.microsoft.com/en-us/library/gg309405.aspx</a></p><pre class="crayon-plain-tag">&lt;fetch distinct='false' no-lock='false' mapping='logical'&gt;
  &lt;entity name='account'&gt;
    &lt;attribute name='name' /&gt;
    &lt;attribute name='accountid' /&gt;
    &lt;attribute name='accountid' rowaggregate='CountChildren' alias='AccountChildren'/&gt;
    &lt;filter type='and'&gt;
      &lt;condition attribute='accountid' operator='under' value='{0}' /&gt;
    &lt;/filter&gt;
  &lt;/entity&gt;
&lt;/fetch&gt;</pre><p>
<h3>Using DateTime Operators with the SSIS Dynamics CRM / Dataverse read task</h3>
<p>This example shows how to write FetchXML query to get all tickets which are created 30 mins before.</p>
<p>Other similar operators are<br />
olderthan-x-hours<br />
olderthan-x-days<br />
olderthan-x-weeks<br />
olderthan-x-months<br />
olderthan-x-years</p>
<p>For a list of supported DateTime operators<br />
<a href="https://msdn.microsoft.com/en-us/library/gg334216.aspx">https://msdn.microsoft.com/en-us/library/gg334216.aspx</a></p>
<p>For a list of all supported operators check below XSD and search for name=&#8221;operator&#8221;<br />
<a href="https://msdn.microsoft.com/en-us/library/gg309405.aspx">https://msdn.microsoft.com/en-us/library/gg309405.aspx</a></p>
<p>To build custom FetxhXML<br />
1. Login to your Dynamics CRM / Dataverse Portal<br />
2. Click on Advanced Find icon (Found next to the search textbox)<br />
3. Once done building query, Click on Download FetchXML icon. Copy that XML into Query editor of Dynamics CRM / Dataverse Source.</p>
<p>For more information about FetchXML query syntax check below links :<br />
<a href="https://msdn.microsoft.com/en-us/library/gg328117.aspx">https://msdn.microsoft.com/en-us/library/gg328117.aspx</a><br />
<a href="https://msdn.microsoft.com/en-us/library/gg328332.aspx">https://msdn.microsoft.com/en-us/library/gg328332.aspx</a></p>
<p>For complete syntax and validation rule for FetchXML check below XSD<br />
<a href="https://msdn.microsoft.com/en-us/library/gg309405.aspx">https://msdn.microsoft.com/en-us/library/gg309405.aspx</a></p><pre class="crayon-plain-tag">&lt;fetch&gt;
  &lt;entity name='incident'&gt;
    &lt;attribute name='title' /&gt;
    &lt;attribute name='ticketnumber' /&gt;
    &lt;attribute name='createdon' /&gt;
    &lt;attribute name='incidentid' /&gt;
    &lt;filter type='and'&gt;
      &lt;condition attribute='createdon' operator='olderthan-x-minutes' value='30' /&gt;
    &lt;/filter&gt;
  &lt;/entity&gt;
&lt;/fetch&gt;</pre><p>
<h3>Query &#8211; All activities (sort, outer join, alias) with the SSIS Dynamics CRM / Dataverse read task</h3>
<p>This example shows how to get all activities performed on lead or contact. It shows how to get attributes from lead and contact by using OUTER JOIN.</p>
<p>This FetchXML is the equivalent of below SQL</p><pre class="crayon-plain-tag">SELECT a.*
, l.firstname as lead_name,l.emailadddress1 as lead_email1
, c.firstname as contact_name
FROM activitypointer a
LEFT OUTER JONI lead l ON a.regardingobjectid=l.leadid
LEFT OUTER JONI lead c ON a.regardingobjectid=c.contactid
ORDER BY a.createdon DESC</pre><p>
To build custom FetxhXML<br />
1. Login to your Dynamics CRM / Dataverse Portal<br />
2. Click on Advanced Find icon (Found next to the search textbox)<br />
3. Once done building query, Click on Download FetchXML icon. Copy that XML into Query editor of Dynamics CRM / Dataverse Source.</p>
<p>For more information about FetchXML query syntax check below links :<br />
<a href="https://msdn.microsoft.com/en-us/library/gg328117.aspx">https://msdn.microsoft.com/en-us/library/gg328117.aspx</a><br />
<a href="https://msdn.microsoft.com/en-us/library/gg328332.aspx">https://msdn.microsoft.com/en-us/library/gg328332.aspx</a></p>
<p>For complete syntax and validation rule for FetchXML check below XSD<br />
<a href="https://msdn.microsoft.com/en-us/library/gg309405.aspx">https://msdn.microsoft.com/en-us/library/gg309405.aspx</a></p><pre class="crayon-plain-tag">&lt;fetch version='1.0' mapping='logical'&gt;
	&lt;entity name='activitypointer'&gt;
		&lt;attribute name='subject' /&gt;
		&lt;attribute name='ownerid' /&gt;
		&lt;attribute name='regardingobjectid' /&gt;
		&lt;attribute name='activitytypecode' /&gt;
		&lt;attribute name='scheduledstart' /&gt;
		&lt;attribute name='scheduledend' /&gt;
		&lt;attribute name='instancetypecode' /&gt;
		&lt;attribute name='community' /&gt;
		&lt;attribute name='actualend' /&gt;
		&lt;attribute name='createdon' /&gt;
		
		&lt;link-entity name='lead' from='leadid' to='regardingobjectid' link-type='outer' alias='l'&gt;
			&lt;attribute name='firstname' alias='lead_name' /&gt;
			&lt;attribute name='emailaddress1' alias='lead_email1' /&gt;
			&lt;attribute name='companyname' alias='lead_company' /&gt;
		&lt;/link-entity&gt;  
		
		&lt;link-entity name='contact' from='contactid' to='regardingobjectid' link-type='outer' alias='c'&gt;
			&lt;attribute name='firstname' alias='contact_name' /&gt;
		&lt;/link-entity&gt;  

		&lt;order attribute='createdon' descending='true' /&gt;
	&lt;/entity&gt;
&lt;/fetch&gt;</pre><p>
<h2>How to use SSIS variables with Fetch XML in SSIS for SSIS Dynamics</h2>
<h2>CRM read</h2>
<p>You can include variables in an XML fetch.</p>
<ol>
<li>
        First, create your variable in the SSDT. Go to SSIS and Variables and create your variable:</p>
<p>        <div id="attachment_3514" style="width: 762px" class="wp-caption aligncenter"><a href="https://zappysys.com/blog/wp-content/uploads/2018/05/ssis-variable-value.jpg"><img loading="lazy" decoding="async" aria-describedby="caption-attachment-3514" class="size-full wp-image-3514" src="https://zappysys.com/blog/wp-content/uploads/2018/05/ssis-variable-value.jpg" alt="ssis-variable-value" width="752" height="113" srcset="https://zappysys.com/blog/wp-content/uploads/2018/05/ssis-variable-value.jpg 752w, https://zappysys.com/blog/wp-content/uploads/2018/05/ssis-variable-value-300x45.jpg 300w" sizes="(max-width: 752px) 100vw, 752px" /></a><p id="caption-attachment-3514" class="wp-caption-text">SSIS variable value</p></div>
    </li>
</ol>
<p>In addition, create your fetch, include the variable in the XM ({{User::value}}):</p><pre class="crayon-plain-tag">&lt;fetch mapping='logical' version='1.0'&gt;
  &lt;entity name='account'&gt;
    &lt;attribute name='name' /&gt;
    &lt;filter&gt;
      &lt;condition attribute='revenue' operator='eq' value='{{User::value}}' /&gt;
    &lt;/filter&gt;
  &lt;/entity&gt;
&lt;/fetch&gt;</pre><p>
<h2>Conclusion about the SSIS Dynamics CRM / Dataverse read task</h2>
<p>To conclude, we can say that the ZS Dynamic CRM source is a great tool to get data from Microsoft CRM Dynamics and export any other destination format. In this article, we learn how to create queries to CRM Dynamics using fetch data. We used several examples to query data. We also learned to use SSIS variables in our queries and how to export the data from Dynamics CRM / Dataverse to SQL Server. <a href="https://zappysys.com/products/ssis-powerpack/download/" target="_blank" rel="noopener">Download SSIS PowerPack</a> to explore Dynamics CRM / Dataverse integration possibilities in SSIS.</p>
<h2>References about SSIS Dynamics CRM / Dataverse read</h2>
<ul>
<li><a href="https://www.microsoft.com/en-us/dynamics365/what-is-crm">What is CRM?</a></li>
<li><a href="https://zappysys.com/products/ssis-powerpack/ssis-dynamics-crm-source-connector/">SSIS Dynamics CRM / Dataverse Source Connector (Dynamics 365 / On-Premises CRM)</a></li>
</ul>
<p>The post <a href="https://zappysys.com/blog/ssis-dynamics-crm-read-import-crm-365-onpremises/">SSIS Dynamics CRM / Dataverse &#8211; Read / Import data into SQL Server</a> appeared first on <a href="https://zappysys.com/blog">ZappySys Blog</a>.</p>
]]></content:encoded>
					
		
		
			</item>
		<item>
		<title>How to use Office 365 API with SSIS (Mail, Calendar, Contacts, OneDrive, Excel)</title>
		<link>https://zappysys.com/blog/calling-office-365-api-using-ssis-graph-api-mail-calendar-contacts-onedrive-excel/</link>
		
		<dc:creator><![CDATA[ZappySys]]></dc:creator>
		<pubDate>Sat, 12 Aug 2017 23:45:15 +0000</pubDate>
				<category><![CDATA[REST API Integration]]></category>
		<category><![CDATA[microsoft graph api]]></category>
		<category><![CDATA[oauth]]></category>
		<category><![CDATA[office 365]]></category>
		<category><![CDATA[ssis]]></category>
		<category><![CDATA[ssis json source]]></category>
		<category><![CDATA[ssis web api destination]]></category>
		<guid isPermaLink="false">http://zappysys.com/blog/?p=1686</guid>

					<description><![CDATA[<p>Introduction In this post you will learn how to access Microsoft Graph API  (Office 365 REST API / Sharepoint API) inside SSIS without any coding. Microsoft Graph API is a unified way to access many Microsoft services API including Office 365 API. In this post we will use SSIS JSON Source / REST API Connector to [&#8230;]</p>
<p>The post <a href="https://zappysys.com/blog/calling-office-365-api-using-ssis-graph-api-mail-calendar-contacts-onedrive-excel/">How to use Office 365 API with SSIS (Mail, Calendar, Contacts, OneDrive, Excel)</a> appeared first on <a href="https://zappysys.com/blog">ZappySys Blog</a>.</p>
]]></description>
										<content:encoded><![CDATA[<h2>Introduction</h2>
<div class="su-note"  style="border-color:#e5dd9d;border-radius:3px;-moz-border-radius:3px;-webkit-border-radius:3px;"><div class="su-note-inner su-u-clearfix su-u-trim" style="background-color:#fff7b7;border-color:#ffffff;color:#333333;border-radius:3px;-moz-border-radius:3px;-webkit-border-radius:3px;">NOTE: <strong>UPDATE:</strong> ZappySys has released a brand new <a href="https://zappysys.com/api/integration-hub/outlook-mail-connector/ssis">API Connector for SSIS Outlook Mail (Office 365)</a> which makes it much simpler to <strong>download attachment, read / search Emails, Users, MailFolders, Send email and more in SSIS</strong> compared to the steps listed in this article. You can still use steps from this article but if you are new to API or want to avoid learning curve with API then use newer approach.</p>
<p>Please visit <a href="https://zappysys.com/api/integration-hub/">this page to see all</a> Pre-Configured ready to use API connectors which you can use in <a href="https://zappysys.com/products/ssis-powerpack/ssis-api-source/">SSIS API Source</a> / <a href="https://zappysys.com/products/ssis-powerpack/ssis-api-destination/">SSIS API Destination</a> OR <a href="https://zappysys.com/products/odbc-powerpack/odbc-api-driver/">API ODBC Driver</a> (for non-SSIS Apps such as Excel, Power BI, Informatica).</div></div>
<p><a href="//zappysys.com/blog/wp-content/uploads/2017/08/microsoft-office-365-api-integration.png"><img loading="lazy" decoding="async" class="alignleft wp-image-1694" src="//zappysys.com/blog/wp-content/uploads/2017/08/microsoft-office-365-api-integration.png" alt="" width="100" height="100" srcset="https://zappysys.com/blog/wp-content/uploads/2017/08/microsoft-office-365-api-integration.png 241w, https://zappysys.com/blog/wp-content/uploads/2017/08/microsoft-office-365-api-integration-150x150.png 150w" sizes="(max-width: 100px) 100vw, 100px" /></a>In this post you will learn how to access <a href="https://developer.microsoft.com/en-us/graph/docs/concepts/overview" target="_blank" rel="noopener">Microsoft Graph API</a>  (Office 365 REST API / Sharepoint API) inside SSIS without any coding. <a href="https://developer.microsoft.com/en-us/graph/docs/concepts/overview" target="_blank" rel="noopener">Microsoft Graph API</a> is a unified way to access many Microsoft services API including <strong>Office 365 API</strong>. In this post we will use <a href="//zappysys.com/products/ssis-powerpack/ssis-json-file-source/" target="_blank" rel="noopener">SSIS JSON Source / REST API Connector</a> to load data from Office 365 to SQL Server.</p>
<p>&nbsp;</p>
<h2>Use Case of Microsoft Graph API</h2>
<p>Here are some use cases why you want to use Microsoft Graph API</p>
<ul>
<li>Read/Write events from <strong>Outlook Calendar</strong></li>
<li>Send <strong>email</strong>  / Read <strong>emails</strong></li>
<li>Get list of files from <strong>OneDrive</strong></li>
<li>Upload/ Download files to <strong>OneDrive</strong></li>
<li>Read/Write <strong>Excel Sheet</strong> (Use range or specific range of specific sheet)</li>
<li>Read <strong>Sharepoint</strong> Document library</li>
<li>Search content from <strong>Sharepoint</strong> document library</li>
<li>Get AD users for your Organization (AD Accounts)</li>
<li>Update OneNote</li>
<li>Track changes to Users, Events, Calendar Items using <a href="https://developer.microsoft.com/en-us/graph/docs/concepts/delta_query_overview" target="_blank" rel="noopener">delta API</a></li>
</ul>
<div class="content_block" id="custom_post_widget-5670"><h2 style="text-align: left;">Register Application (OAuth2 App for Graph API)</h2>
<p style="text-align: left;">The first step to access any Office 365 API / Graph API is to register an OAuth App in the Azure Portal. After
following these steps, you will get the following two items to use in the next section:</p>

<ul style="text-align: left;">
 	<li>Application Id</li>
 	<li>Application Secret</li>
</ul>
<p style="text-align: left;">In this section, you will learn how to register a custom app in Microsoft Azure portal that will allow access to the
OneDrive. So, let's get started -</p>

<ol>
 	<li style="text-align: left;">Log into <a href="https://portal.azure.com/#blade/Microsoft_AAD_IAM/ActiveDirectoryMenuBlade/RegisteredApps">Microsoft
Azure portal</a> to register a custom app.</li>
 	<li style="text-align: left;">Register a new application by clicking New Registration link.<a href="https://zappysys.com/blog/wp-content/uploads/2020/07/NewRegistration.png"><img loading="lazy" decoding="async" class="size-full wp-image-9034" src="https://zappysys.com/blog/wp-content/uploads/2020/07/NewRegistration.png" alt="New App Registration in Azure portal" width="748" height="221" srcset="https://zappysys.com/blog/wp-content/uploads/2020/07/NewRegistration.png 748w, https://zappysys.com/blog/wp-content/uploads/2020/07/NewRegistration-300x89.png 300w" sizes="(max-width: 748px) 100vw, 748px" /></a></li>
 	<li style="text-align: left;">Provide the name of the custom app and who can access the app in the organization.<a href="https://zappysys.com/blog/wp-content/uploads/2020/07/RegisterOneDriveApp-1.jpg"><img loading="lazy" decoding="async" class="wp-image-9005 size-full" src="https://zappysys.com/blog/wp-content/uploads/2020/07/RegisterOneDriveApp-1.jpg" alt="Register an OneDrive App" width="610" height="518" srcset="https://zappysys.com/blog/wp-content/uploads/2020/07/RegisterOneDriveApp-1.jpg 610w, https://zappysys.com/blog/wp-content/uploads/2020/07/RegisterOneDriveApp-1-300x255.jpg 300w" sizes="(max-width: 610px) 100vw, 610px" /></a></li>
 	<li style="text-align: left;">Go to the App overview and add a Redirect URL.<a href="https://zappysys.com/blog/wp-content/uploads/2020/07/RedirectURI-1.jpg"><img loading="lazy" decoding="async" class="wp-image-9044 size-full" src="https://zappysys.com/blog/wp-content/uploads/2020/07/RedirectURI-1.jpg" alt="Add a Redirect URL" width="937" height="122" srcset="https://zappysys.com/blog/wp-content/uploads/2020/07/RedirectURI-1.jpg 937w, https://zappysys.com/blog/wp-content/uploads/2020/07/RedirectURI-1-300x39.jpg 300w, https://zappysys.com/blog/wp-content/uploads/2020/07/RedirectURI-1-768x100.jpg 768w" sizes="(max-width: 937px) 100vw, 937px" /></a></li>
 	<li style="text-align: left;">Click on "Add a Platform" under Platform Configuration section and then select "Web" under Web applications
section to enter a Redirect URL.
<pre class="lang:default decode:true">https://zappysys.com/oauth</pre>
<a href="https://zappysys.com/blog/wp-content/uploads/2020/07/RedirectURI2.jpg"><img loading="lazy" decoding="async" class="size-full wp-image-9007" src="https://zappysys.com/blog/wp-content/uploads/2020/07/RedirectURI2.jpg" alt="Redirect URL" width="466" height="564" srcset="https://zappysys.com/blog/wp-content/uploads/2020/07/RedirectURI2.jpg 466w, https://zappysys.com/blog/wp-content/uploads/2020/07/RedirectURI2-248x300.jpg 248w" sizes="(max-width: 466px) 100vw, 466px" /></a></li>
 	<li style="text-align: left;">Create a Client Secret key which will be used to Authenticate the custom Azure app.<a href="https://zappysys.com/blog/wp-content/uploads/2020/07/ClientSecret.jpg"><img loading="lazy" decoding="async" class="size-full wp-image-9010" src="https://zappysys.com/blog/wp-content/uploads/2020/07/ClientSecret.jpg" alt="Add a Client Secret" width="576" height="403" srcset="https://zappysys.com/blog/wp-content/uploads/2020/07/ClientSecret.jpg 576w, https://zappysys.com/blog/wp-content/uploads/2020/07/ClientSecret-300x210.jpg 300w" sizes="(max-width: 576px) 100vw, 576px" /></a><a href="https://zappysys.com/blog/wp-content/uploads/2020/07/ClientSecret2.jpg"><img loading="lazy" decoding="async" class="size-full wp-image-9011" src="https://zappysys.com/blog/wp-content/uploads/2020/07/ClientSecret2.jpg" alt="Secret Key Expiration Period" width="208" height="259" /></a><a href="https://zappysys.com/blog/wp-content/uploads/2020/07/ClientSecret3.jpg"><img loading="lazy" decoding="async" class="size-full wp-image-9012" src="https://zappysys.com/blog/wp-content/uploads/2020/07/ClientSecret3.jpg" alt="Specify Secret Key" width="1024" height="176" srcset="https://zappysys.com/blog/wp-content/uploads/2020/07/ClientSecret3.jpg 1024w, https://zappysys.com/blog/wp-content/uploads/2020/07/ClientSecret3-300x52.jpg 300w, https://zappysys.com/blog/wp-content/uploads/2020/07/ClientSecret3-768x132.jpg 768w" sizes="(max-width: 1024px) 100vw, 1024px" /></a>
<div><strong>Note</strong> - Take a note of <strong>Client Secret</strong>, it will be required while
configuring OAuth connection in the SSIS later</div></li>
 	<li style="text-align: left;">Add API Permissions.<a href="https://zappysys.com/blog/wp-content/uploads/2020/07/APIPermissions.jpg"><img loading="lazy" decoding="async" class="size-full wp-image-9008" src="https://zappysys.com/blog/wp-content/uploads/2020/07/APIPermissions.jpg" alt="OneDrive API Permissions" width="1291" height="415" /></a></li>
 	<li style="text-align: left;">Select following permissions from the Delegated Permissions section.
<pre class="lang:default decode:true">User.ReadBasic.All
Files.Read
offline_access</pre>
<a href="https://zappysys.com/blog/wp-content/uploads/2020/07/APIPermissions2.jpg"><img loading="lazy" decoding="async" class="size-full wp-image-9009" src="https://zappysys.com/blog/wp-content/uploads/2020/07/APIPermissions2.jpg" alt="Select Delegated Permissions" width="512" height="571" srcset="https://zappysys.com/blog/wp-content/uploads/2020/07/APIPermissions2.jpg 512w, https://zappysys.com/blog/wp-content/uploads/2020/07/APIPermissions2-269x300.jpg 269w" sizes="(max-width: 512px) 100vw, 512px" /></a></li>
 	<li>Take a note of Client ID, it will be required while configuring OAuth connection in the SSIS later.<a href="https://zappysys.com/blog/wp-content/uploads/2020/07/ClientSecret4.jpg"><img loading="lazy" decoding="async" class="wp-image-9013 size-full alignleft" src="https://zappysys.com/blog/wp-content/uploads/2020/07/ClientSecret4.jpg" alt="App Client ID" width="810" height="274" /></a></li>
</ol></div>
<h2>Step-By-Step : Access Outlook.com Emails using SSIS</h2>
<p>Now lets look at examples to access your outlook.com emails using SSIS. You can use same techniques to call pretty much any Office 365 API.</p>
<h3>Configure SSIS OAuth Connection for Graph REST API</h3>
<p>First step to access any Graph API is configure OAuth connection</p>
<ol>
<li>Open Visual Studio</li>
<li>Open existing SSIS Project or create new using File &gt; New &gt; Project &gt; Choose “Integration Services Project” Type under Business Intelligence template category</li>
<li>Open Package</li>
<li>Right click inside Connection Managers area and click “New Connection…”</li>
<li>From the connection type list select “ZS-OAUTH” connection type.
<div id="attachment_1569" style="width: 687px" class="wp-caption alignnone"><a href="//zappysys.com/blog/wp-content/uploads/2017/07/ssis-oauth-create-new-connection.png"><img loading="lazy" decoding="async" aria-describedby="caption-attachment-1569" class="size-full wp-image-1569" src="//zappysys.com/blog/wp-content/uploads/2017/07/ssis-oauth-create-new-connection.png" alt="Create new SSIS OAuth API Connection Manager" width="677" height="220" srcset="https://zappysys.com/blog/wp-content/uploads/2017/07/ssis-oauth-create-new-connection.png 677w, https://zappysys.com/blog/wp-content/uploads/2017/07/ssis-oauth-create-new-connection-300x97.png 300w" sizes="(max-width: 677px) 100vw, 677px" /></a><p id="caption-attachment-1569" class="wp-caption-text">Create new SSIS OAuth API Connection Manager</p></div></li>
<li>On the OAuth Connection Manager configure following options
<ol>
<li>Select &#8220;Custom&#8221; from Provider dropdown</li>
<li>Select OAuth2 from OAuth version</li>
<li>Enter your Application Id and Secret Key (i.e. App Password) obtained in the previous section <a href="https://apps.dev.microsoft.com/#/appList" target="_blank" rel="noopener">from here</a>.</li>
<li>Enter following URL in the Authorization URL<br />
<pre class="crayon-plain-tag">https://login.microsoftonline.com/common/oauth2/v2.0/authorize</pre>
</li>
<li>Enter the following URL in the token URL field<br />
<pre class="crayon-plain-tag">https://login.microsoftonline.com/common/oauth2/v2.0/token</pre>
</li>
<li>Enter the following <a href="https://developer.microsoft.com/en-us/graph/docs/authorization/permission_scopes" target="_blank" rel="noopener">Graph API Scopes</a> (each scope must be entered in a new line).<br />
<pre class="crayon-plain-tag">user.read
mail.read
offline_access</pre>
<div class="su-note"  style="border-color:#e5dd9d;border-radius:3px;-moz-border-radius:3px;-webkit-border-radius:3px;"><div class="su-note-inner su-u-clearfix su-u-trim" style="background-color:#fff7b7;border-color:#ffffff;color:#333333;border-radius:3px;-moz-border-radius:3px;-webkit-border-radius:3px;">NOTE: Always include <strong>offline_access</strong> scope returns refreh_token which allows you to renew token without going through login process again. For more information about which scopes needed always refer to API help page (e.g. if you want to read mail using <a href="https://developer.microsoft.com/en-us/graph/docs/api-reference/v1.0/api/user_list_messages" target="_blank" rel="noopener">this API</a> then you will see it says you can use <strong>Mail.Read</strong> or <strong>Mail.ReadWrite</strong> scope).</div></div></li>
<li>Go to Advanced tab and enter the following URL in the Callback/Return URL (Assuming exact same URL used when you registered App in the previous section)<br />
<pre class="crayon-plain-tag">https://zappysys.com/oauth</pre>
</li>
<li>Now go back to first tab and Click Generate Token. When prompted Login using your Personal Microsoft Account or Work Account (Office 365 or AD login)</li>
<li>After login you will see Accept option just click it. If things go right then you will see Access Token and Refresh Token fields will be populated.</li>
</ol>
</li>
<li>Once all configured you can click Test to make sure connection works.
<div id="attachment_1691" style="width: 685px" class="wp-caption alignnone"><a href="//zappysys.com/blog/wp-content/uploads/2017/08/ssis-office-365-graph-rest-api-oauth-connection-manager.png"><img loading="lazy" decoding="async" aria-describedby="caption-attachment-1691" class="size-full wp-image-1691" src="//zappysys.com/blog/wp-content/uploads/2017/08/ssis-office-365-graph-rest-api-oauth-connection-manager.png" alt="SSIS OAuth COnnection Manager for Office 365 REST API / Microsoft Graph API" width="675" height="654" srcset="https://zappysys.com/blog/wp-content/uploads/2017/08/ssis-office-365-graph-rest-api-oauth-connection-manager.png 675w, https://zappysys.com/blog/wp-content/uploads/2017/08/ssis-office-365-graph-rest-api-oauth-connection-manager-300x291.png 300w" sizes="(max-width: 675px) 100vw, 675px" /></a><p id="caption-attachment-1691" class="wp-caption-text">SSIS OAuth Connection Manager for Office 365 REST API / Microsoft Graph API</p></div></li>
</ol>
<h3></h3>
<div class="su-note"  style="border-color:#e5da9d;border-radius:3px;-moz-border-radius:3px;-webkit-border-radius:3px;"><div class="su-note-inner su-u-clearfix su-u-trim" style="background-color:#fff4b7;border-color:#ffffff;color:#333333;border-radius:3px;-moz-border-radius:3px;-webkit-border-radius:3px;"><strong>NOTE:</strong> Typically RefreshToken is longed lived but in some cases they may expire soon too. If that&#8217;s the case then you can configure above oauth connection for <a href="https://docs.microsoft.com/en-us/azure/active-directory/develop/v1-protocols-oauth-code" target="_blank" rel="noopener">Changing RefreshToken pattern</a>. Simply enter token file path and re-authenticate by clicking Generate Token. After that each time you make an API call it will save new refresh token in file.</div></div>
<h3>Configure SSIS JSON/REST API Source</h3>
<p>Once you configure OAuth connection you are ready to read data from Office 365 API. Lets look at step by step how to read emails using Mail API and save to SQL Server.</p>
<ol>
<li>Drag and drop Data flow task from SSIS toolbox</li>
<li>Goto data flow designer and drag and drop <a href="//zappysys.com/products/ssis-powerpack/ssis-json-file-source/" target="_blank" rel="noopener">ZS JSON Source/REST API Connector</a> on the designer</li>
<li>Double click to edit JSON Source.</li>
<li>In the URL field enter below URL<br />
<pre class="crayon-plain-tag">https://graph.microsoft.com/v1.0/me/messages</pre>
To customize URL with additional parameters check <a href="https://developer.microsoft.com/en-us/graph/docs/overview/query_parameters" target="_blank" rel="noopener">this help link</a>. It&#8217;s a standard OData Protocol so you can leverage many common OData features (e.g. Use $top parameters to set pageSize. Default is 10 for List Mail but you can include more records per response by changing it such as <strong>&#8230;/messages?$top=50</strong>).</li>
<li>Check Use credentials option</li>
<li>From the connections dropdown select OAuth Connection manager created in the previous section</li>
<li>Change Data Format option to <strong>OData </strong></li>
<li>In the Filter enter following or click &#8220;Select Filter&#8221; and select Value Array node &gt; Click OK.<br />
<pre class="crayon-plain-tag">$.value[*]</pre>
</li>
<li>In the Max rows set to 200 so we don&#8217;t pull all data for now 🙂 &#8230; This is our hello world example.</li>
<li>Now click Preview to see data. If all is well then Save UI by clicking OK
<div id="attachment_1693" style="width: 852px" class="wp-caption alignnone"><a href="//zappysys.com/blog/wp-content/uploads/2017/08/ssis-get-data-from-microsoft-graph-api-office-365-json-rest-api-source.png"><img loading="lazy" decoding="async" aria-describedby="caption-attachment-1693" class="size-full wp-image-1693" src="//zappysys.com/blog/wp-content/uploads/2017/08/ssis-get-data-from-microsoft-graph-api-office-365-json-rest-api-source.png" alt="SSIS JSON Source - Get data from Microsoft Graph API (Office 365 API - Read Mail Example)" width="842" height="695" srcset="https://zappysys.com/blog/wp-content/uploads/2017/08/ssis-get-data-from-microsoft-graph-api-office-365-json-rest-api-source.png 842w, https://zappysys.com/blog/wp-content/uploads/2017/08/ssis-get-data-from-microsoft-graph-api-office-365-json-rest-api-source-300x248.png 300w, https://zappysys.com/blog/wp-content/uploads/2017/08/ssis-get-data-from-microsoft-graph-api-office-365-json-rest-api-source-768x634.png 768w" sizes="(max-width: 842px) 100vw, 842px" /></a><p id="caption-attachment-1693" class="wp-caption-text">SSIS JSON Source &#8211; Get data from Microsoft Graph API (Office 365 API &#8211; Read Mail Example)</p></div></li>
</ol>
<h3>Loading Graph API / Office 365 data to SQL Server</h3>
<p>Now last step is loading Outlook data to SQL Server. For example purpose we will load data into SQL Server but you can load into any Target (e.g. Flat file, Oracle, Excel) using Microsoft or ZappySys Destination connectors</p>
<p>To load Office 365 data into SQL Server perform the following steps</p>
<ol>
<li>Drag OLEDB destination on Data Flow surface</li>
<li>Connect ZS JSON Source to Destination</li>
<li>On OLEDB destination select / create new SQL Connection and then Click &#8220;New Table&#8221;</li>
<li>Click on Mappings tab and click OK to save</li>
<li>Execute Package</li>
</ol>
<div id="attachment_1617" style="width: 792px" class="wp-caption alignnone"><a href="//zappysys.com/blog/wp-content/uploads/2017/07/ssis-xero-to-sql-server-data-load.png"><img loading="lazy" decoding="async" aria-describedby="caption-attachment-1617" class="size-full wp-image-1617" src="//zappysys.com/blog/wp-content/uploads/2017/07/ssis-xero-to-sql-server-data-load.png" alt="Configure SSIS OLEDB Destination - Loading Xero Data into SQL Server Table" width="782" height="593" srcset="https://zappysys.com/blog/wp-content/uploads/2017/07/ssis-xero-to-sql-server-data-load.png 782w, https://zappysys.com/blog/wp-content/uploads/2017/07/ssis-xero-to-sql-server-data-load-300x227.png 300w, https://zappysys.com/blog/wp-content/uploads/2017/07/ssis-xero-to-sql-server-data-load-768x582.png 768w" sizes="(max-width: 782px) 100vw, 782px" /></a><p id="caption-attachment-1617" class="wp-caption-text">Configure SSIS OLEDB Destination &#8211; Loading Xero Data into SQL Server Table</p></div>
<div id="attachment_1618" style="width: 744px" class="wp-caption alignnone"><a href="//zappysys.com/blog/wp-content/uploads/2017/07/ssis-xero-sql-server-load-mappings.png"><img loading="lazy" decoding="async" aria-describedby="caption-attachment-1618" class="size-full wp-image-1618" src="//zappysys.com/blog/wp-content/uploads/2017/07/ssis-xero-sql-server-load-mappings.png" alt="Xero to SQL Server Column Mappings for OLEDB Destination" width="734" height="543" srcset="https://zappysys.com/blog/wp-content/uploads/2017/07/ssis-xero-sql-server-load-mappings.png 734w, https://zappysys.com/blog/wp-content/uploads/2017/07/ssis-xero-sql-server-load-mappings-300x222.png 300w" sizes="(max-width: 734px) 100vw, 734px" /></a><p id="caption-attachment-1618" class="wp-caption-text">Graph API / Office 365 to SQL Server Column Mappings for OLEDB Destination</p></div>
<div id="attachment_1619" style="width: 293px" class="wp-caption alignnone"><a href="//zappysys.com/blog/wp-content/uploads/2017/07/ssis-loading-data-from-xero-to-sql-server.png"><img loading="lazy" decoding="async" aria-describedby="caption-attachment-1619" class="size-full wp-image-1619" src="//zappysys.com/blog/wp-content/uploads/2017/07/ssis-loading-data-from-xero-to-sql-server.png" alt="Loading Xero data to SQL Server in SSIS" width="283" height="391" srcset="https://zappysys.com/blog/wp-content/uploads/2017/07/ssis-loading-data-from-xero-to-sql-server.png 283w, https://zappysys.com/blog/wp-content/uploads/2017/07/ssis-loading-data-from-xero-to-sql-server-217x300.png 217w" sizes="(max-width: 283px) 100vw, 283px" /></a><p id="caption-attachment-1619" class="wp-caption-text">Loading Graph REST API  / Office 365 data to SQL Server in SSIS</p></div>
<h2>POST data to Graph API (Insert or Update)</h2>
<p>So far we have seen how to read data from Office 365 API. Now let&#8217;s look at how to write data to Office 365.</p>
<p>There are two ways you can achieve this.</p>
<ol>
<li>Use <a href="//zappysys.com/products/ssis-powerpack/ssis-web-api-destination-connector/" target="_blank" rel="noopener">Web API Destination</a> in Data Flow</li>
<li>Use <a href="//zappysys.com/products/ssis-powerpack/ssis-rest-api-web-service-task/" target="_blank" rel="noopener">REST API Task</a> in Control Flow</li>
</ol>
<p>Read this article to learn more about <a href="//zappysys.com/blog/http-post-in-ssis-send-data-to-web-api-url-json-xml/" target="_blank" rel="noopener">API POST using SSIS</a></p>
<h3>Using SSIS Web API Task (Write data from SQL Server to Office 365 / Graph API)</h3>
<h3><img decoding="async" src="https://i0.wp.com/zappysys.com/onlinehelp/ssis-powerpack/scr/images/web-api-destination/ssis-web-api-destination-post-json-to-rest-api-url.png?resize=503%2C403" alt="SSIS Web API Destination - POST JSON to REST API Endpoint, Create / Update records" /></h3>
<h3>Using REST API Task to POST data to Graph API</h3>
<p>If you have JSON/XML data already prepared and if you like to POST it to Graph API then REST API Task would be easy to use.</p>
<p>REST API Task Body can be direct string, variable (e.g. {{User::varSomeData}} or <a href="https://zappysys.com/blog/rest-api-file-upload-using-ssis-multi-part-post/" target="_blank" rel="noopener">Body can come from File </a></p>
<div id="attachment_1616" style="width: 872px" class="wp-caption alignnone"><a href="//zappysys.com/blog/wp-content/uploads/2017/07/ssis-post-data-xero-api-create-contacts-example.png"><img loading="lazy" decoding="async" aria-describedby="caption-attachment-1616" class="size-full wp-image-1616" src="//zappysys.com/blog/wp-content/uploads/2017/07/ssis-post-data-xero-api-create-contacts-example.png" alt="SSIS REST API Task - POST data to Xero (Create contacts)" width="862" height="602" srcset="https://zappysys.com/blog/wp-content/uploads/2017/07/ssis-post-data-xero-api-create-contacts-example.png 862w, https://zappysys.com/blog/wp-content/uploads/2017/07/ssis-post-data-xero-api-create-contacts-example-300x210.png 300w, https://zappysys.com/blog/wp-content/uploads/2017/07/ssis-post-data-xero-api-create-contacts-example-768x536.png 768w" sizes="(max-width: 862px) 100vw, 862px" /></a><p id="caption-attachment-1616" class="wp-caption-text">SSIS REST API Task &#8211; POST data to Graph API</p></div>
<h2>Download file from OneDrive</h2>
<p>To download file from OneDrive perform these steps</p>
<p><a href="https://zappysys.zendesk.com/hc/en-us/articles/115005010573-How-to-download-file-from-OneDrive-using-Graph-API" target="_blank" rel="noopener">https://zappysys.zendesk.com/hc/en-us/articles/115005010573-How-to-download-file-from-OneDrive-using-Graph-API</a></p>
<h2>Upload file to OneDrive</h2>
<p><a href="https://zappysys.zendesk.com/hc/en-us/articles/115004893713-How-to-upload-file-to-OneDrive-using-Office-365-Graph-API" target="_blank" rel="noopener">https://zappysys.zendesk.com/hc/en-us/articles/115004893713-How-to-upload-file-to-OneDrive-using-Office-365-Graph-API</a></p>
<h2>Reading Office Excel Sheets from OneDrive</h2>
<p>JSON Source also support reading API response which returns 2D arrays. Such as <a href="https://developer.microsoft.com/en-us/graph/docs/api-reference/v1.0/resources/excel" target="_blank" rel="noopener">Office Excel Spreadsheet API</a> to read excel data. Check <a href="//zappysys.com/blog/get-data-google-spreadsheet-using-ssis/" target="_blank" rel="noopener">this blog post</a> to learn similar scenario to parse 2D arrays. There are few other options for parsing 2D arrays which are <a href="//zappysys.com/blog/parse-multi-dimensional-json-array-ssis/" target="_blank" rel="noopener">documented here</a>.</p><pre class="crayon-plain-tag">https://graph.microsoft.com/v1.0/me/drive/items/01CYZLFJDYxxxxxxx/workbook/worksheets('test')/range(address='A1:B200')</pre><p>
<h2>Testing Office 365 API using Graph API Explorer</h2>
<p>If you like to test API request/response inside browser then Microsoft provides really great tool to called Graph API Explorer. <a href="https://developer.microsoft.com/en-us/graph/graph-explorer" target="_blank" rel="noopener">Click here to try Graph API Explorer</a>.</p>
<p>See below screenshot</p>
<p><a href="//zappysys.com/blog/wp-content/uploads/2017/08/test-office-365-graph-api-from-rest-api-explorer-read-mail-calendar-people-onedrive.png"><img loading="lazy" decoding="async" class="alignnone size-full wp-image-1701" src="//zappysys.com/blog/wp-content/uploads/2017/08/test-office-365-graph-api-from-rest-api-explorer-read-mail-calendar-people-onedrive.png" alt="" width="1085" height="538" srcset="https://zappysys.com/blog/wp-content/uploads/2017/08/test-office-365-graph-api-from-rest-api-explorer-read-mail-calendar-people-onedrive.png 1085w, https://zappysys.com/blog/wp-content/uploads/2017/08/test-office-365-graph-api-from-rest-api-explorer-read-mail-calendar-people-onedrive-300x149.png 300w, https://zappysys.com/blog/wp-content/uploads/2017/08/test-office-365-graph-api-from-rest-api-explorer-read-mail-calendar-people-onedrive-768x381.png 768w, https://zappysys.com/blog/wp-content/uploads/2017/08/test-office-365-graph-api-from-rest-api-explorer-read-mail-calendar-people-onedrive-1024x508.png 1024w" sizes="(max-width: 1085px) 100vw, 1085px" /></a></p>
<h2>Common Errors</h2>
<div class="content_block" id="custom_post_widget-1887"><h3>Truncation related error</h3>
<p style="text-align: justify;">The most common error you may face when you run an SSIS package is truncation error. During the design time only 300 rows are scanned from a source (a file or a REST API call response) to detect datatypes but at runtime, it is likely you will retrieve far more records. So it is possible that you will get longer strings than initially expected. For detailed instructions on how to fix common metadata related errors read an article "<a href="//zappysys.com/blog/handling-ssis-component-metadata-issues/" target="_blank" rel="noopener">How to handle SSIS errors (truncation, metadata issues)</a>".</p>

<h3>Authentication related error</h3>
Another frequent error you may get is an authentication error, which happens when you deploy/copy a package to another machine and run it there. Check <a href="#Deployment_to_Production">the paragraph below</a> to see why it happens and how to solve this problem.</div>
<h2>Deployment to Production</h2>
<div class="content_block" id="custom_post_widget-1932"><p style="text-align: justify;">In SSIS package <a href="https://docs.microsoft.com/en-us/sql/integration-services/security/access-control-for-sensitive-data-in-packages" target="_blank" rel="noopener">sensitive data such as tokens and passwords are by default encrypted by SSIS</a> with your Windows account which you use to create a package. So SSIS will fail to decrypt tokens/passwords when you run it from another machine using another Windows account. To circumvent this when you are creating an SSIS package which uses authentication components (e.g. an <a href="https://zappysys.com/onlinehelp/ssis-powerpack/scr/ssis-oauth-connection-manager.htm" target="_blank" rel="noopener">OAuth Connection Manager</a> or an <a href="https://zappysys.com/onlinehelp/ssis-powerpack/scr/ssis-http-connection-manager.htm" target="_blank" rel="noopener">HTTP Connection Manager</a> with credentials, etc.), consider using parameters/variables to pass tokens/passwords. In this way, you won’t face authentication related errors when a package is deployed to a production server.</p>
<p style="text-align: justify;">Check our article on <a href="https://zappysys.com/blog/how-to-run-an-ssis-package-with-sensitive-data-on-sql-server/" target="_blank" rel="noopener">how to configure packages with sensitive data on your production or development server</a>.</p></div>
<h2><span id="ConclusionWhat8217s_next">Conclusion. What’s next?</span></h2>
<p>In this article we have learned how to load data from Microsoft Graph API to SQL Server using SSIS ( drag and drop approach without coding). We used <a href="https://zappysys.com/products/ssis-powerpack/" target="_blank" rel="noopener">SSIS JSON / REST API Connector</a> to extract data from Outlook Mail using OAuth. JSON Source makes it super simple to parsing complex / large JSON Files or any Web API Response into rows and column so you can load into database like SQL Server. <a href="//zappysys.com/products/ssis-powerpack/">Download SSIS PowerPack</a> to try many other automation scenarios not discussed in this article.</p>
<p><strong>Keywords:</strong></p>
<p>Office 365 API Integration with SQL Server | How to extract Office 365 data in SSIS? | How to read outlook mail, calendar event and contacts? | Calling Microsoft Graph API using SSIS. | Office 365 to SQL Server | SQL Server to Office 365 | SSIS Office 365 API Integration | SSIS Graph API Integration</p>
<p>&nbsp;</p>
<p>The post <a href="https://zappysys.com/blog/calling-office-365-api-using-ssis-graph-api-mail-calendar-contacts-onedrive-excel/">How to use Office 365 API with SSIS (Mail, Calendar, Contacts, OneDrive, Excel)</a> appeared first on <a href="https://zappysys.com/blog">ZappySys Blog</a>.</p>
]]></content:encoded>
					
		
		
			</item>
	</channel>
</rss>
