Skip to main content

Creating a BYODB and Configuring a Full and Incremental Entity Export

Page 1

Dynamics Companions BARE BONES CONFIGURATION GUIDES

MODULE 1: Creating a BYODB and Configuring a Full and Incremental Entity Export

CONFIGURATION BLUEPRINT

TABLE OF CONTENTS Creating a BYODB and Configuring a Full and Incremental Entity Export

Creating a BYODB and Configuring a Full and Incremental Entity Export .... 2 Creating an Azure SQL Database ........................................................... 3 Configuring an Entity Export to Database ........................................... 26 Publishing Entities to the BYODB Datasource ..................................... 40 Creating an Entity Export Project ........................................................ 54 Enabling Change Tracking on Data Entities ......................................... 75

In a production environment for Dynamics 365 for Finance & Operations, the primary database is locked down so that you cannot query or maintain the database directly.

Creating an Incremental Data Export Project...................................... 79 Conclusion ......................................................................................... 103

But there are a lot of times that we would like to have access to the data so that we can create integrations with other systems, to publish data out for others view or even to report off through other reporting tools. So the big question is how do you do this?

www.dynamicscompanions.com Dynamics Companions

-1-

www.blindsquirrelpublishing.com Š 2017 Blind Squirrel Publishing, LLC , All Rights Reserved


DYNAMICS COMPANIONS CONFIGURATION BLUEPRINT

CREATING A BYODB AND CONFIGURING A FULL AND INCREMENTAL ENTITY EXPORT

Creating a BYODB and Configuring a Full and Incremental Entity Export In a production environment for Dynamics 365 for Finance & Operations, the primary database is locked down so that you cannot query or maintain the database directly. But there are a lot of times that we would like to have access to the data so that we can create integrations with other systems, to publish data out for others view or even to report off through other reporting tools. So the big question is how do you do this? The answer is through the BYODB (Bring Your Own Database) feature within Dynamics 365 that allows us to attach an external SQL database to our instance and then publish any of the data entities that are available within the Data Management framework out to the database. In addition to doing full exports of the data, we can also schedule incremental updates as well that take advantage of the change tracking feature to push only the data that has changed within the entity rather than all of the data. Although this may seem like a daunting effort, it’s not really that hard, and in this walkthrough we will show how to get everything wired up.

Topics Covered •

Creating an Azure SQL Database

Configuring an Entity Export to Database

Publishing Entities to the BYODB Datasource

Creating an Entity Export Project

Enabling Change Tracking on Data Entities

Creating an Incremental Data Export Project

www.dynamicscompanions.com Dynamics Companions

-2-

www.blindsquirrelpublishing.com © 2018 Blind Squirrel Publishing, LLC , All Rights Reserved


DYNAMICS COMPANIONS CONFIGURATION BLUEPRINT

CREATING A BYODB AND CONFIGURING A FULL AND INCREMENTAL ENTITY EXPORT

Creating an Azure SQL Database The first step in the process is to create a new Azure SQL Server Database that we will use as the BYODB for Dynamics. Spoiler Alert: This will cost you some Azure $ to set up.

How to do it‌ We will start off by opening up our Azure Portal by going to portal.azure.com.

Next we will want to set the Server admin login username that we will be using to authenticate with.

Here we also created a new workspace that we can use to track all of the resources that we create for this project.

For this example we set the Server admin login to the same as the Server name to make it easier to remember.

Now we will want to create a new SQL Server resource that we will house our BYODB in.

And then we will want to specify the Password that we will be using to authenticate against the database with.

To do this, just click on the Create a resource button on the left hand side of the Azure portal.

Next we will want to either create a new Resource group that we will put the SQL Server resource into, or use an exisiting Resource group.

To find the SQL server resource template, just type in sql into the filter box. Then select the SQL server (logical server) resource type. When the details for the SQL server (logical server) are displayed, just click on the Create button to create the resource.

To make it easier to track down all the resources used for this project we will create a new Resource group and set it to mufifebyodb.

This will take us to the configuration pane for the SQL server that we are creating.

And finally we will want to add this resource to our workspace so we checked the Pin to dashboard option.

We will now need to give our SQL Server a Server name.

After we have done that we can just click on the Create button to get Auzre to configure the resource for us.

For this database we will set the Server name to mufifebyodb.

That will return us to our workspace and we will see that the resource is queued for creation. www.dynamicscompanions.com Dynamics Companions

-3-

www.blindsquirrelpublishing.com Š 2018 Blind Squirrel Publishing, LLC , All Rights Reserved


DYNAMICS COMPANIONS CONFIGURATION BLUEPRINT

CREATING A BYODB AND CONFIGURING A FULL AND INCREMENTAL ENTITY EXPORT

After a couple of seconds, we will have a new SQL server resource and we will be taken to the configuration page.

By default the Standard database is selected, which (at the time of writing this) is going to cost about $15 a month.

Now we will want to add a new SQL Database to the server.

If you are feeling richer then you could select a Premium database, but for this example it’s a little bit too expensive.

To do this, just click on the + New database link in the menu bar for the SQL server.

So we will select the Standard database template and click on the Apply button.

This will open up the SQL database configuration form where we will be able to specify the details for our new BYODB database.

After we have done that we can check the Pin to dashboard option and then click on the OK button.

Start off by giving the new SQL database a Database name.

This will kick off the process to create the Azure SQL database.

For this example we will keep everything consistent and give our SQL database a Database name of mufifebyodb.

After a few seconds we will have a newly minted SQL database that we can start using.

Next we will want to choose the type of database that we will want to create. If we click on the Pricing for field we will see all of the different SQL options and also how much it will cost us a month to run the SQL server database.

www.dynamicscompanions.com Dynamics Companions

Before we move onto the next step we will want to find the Connection string for the database, and to do that we will want to click on the Show database connection string link. This will open up a page with all of the connection string examples that we will need later on in the process.

-4-

www.blindsquirrelpublishing.com Š 2018 Blind Squirrel Publishing, LLC , All Rights Reserved


DYNAMICS COMPANIONS CONFIGURATION BLUEPRINT

CREATING A BYODB AND CONFIGURING A FULL AND INCREMENTAL ENTITY EXPORT

Creating an Azure SQL Database How to do it…

We will start off by opening up our Azure Portal by going to portal.azure.com. Here we also created a new workspace that we can use to track all of the resources that we create for this project.

www.dynamicscompanions.com Dynamics Companions

-5-

www.blindsquirrelpublishing.com © 2018 Blind Squirrel Publishing, LLC , All Rights Reserved


DYNAMICS COMPANIONS CONFIGURATION BLUEPRINT

CREATING A BYODB AND CONFIGURING A FULL AND INCREMENTAL ENTITY EXPORT

Creating an Azure SQL Database How to do it…

Now we will want to create a new SQL Server resource that we will house our BYODB in. To do this, just click on the Create a resource button on the left hand side of the Azure portal.

www.dynamicscompanions.com Dynamics Companions

-6-

www.blindsquirrelpublishing.com © 2018 Blind Squirrel Publishing, LLC , All Rights Reserved


DYNAMICS COMPANIONS CONFIGURATION BLUEPRINT

CREATING A BYODB AND CONFIGURING A FULL AND INCREMENTAL ENTITY EXPORT

Creating an Azure SQL Database How to do it…

To find the SQL server resource template, just type in sql into the filter box. Then select the SQL server (logical server) resource type.

www.dynamicscompanions.com Dynamics Companions

-7-

www.blindsquirrelpublishing.com © 2018 Blind Squirrel Publishing, LLC , All Rights Reserved


DYNAMICS COMPANIONS CONFIGURATION BLUEPRINT

CREATING A BYODB AND CONFIGURING A FULL AND INCREMENTAL ENTITY EXPORT

Creating an Azure SQL Database How to do it…

When the details for the SQL server (logical server) are displayed, just click on the Create button to create the resource.

www.dynamicscompanions.com Dynamics Companions

-8-

www.blindsquirrelpublishing.com © 2018 Blind Squirrel Publishing, LLC , All Rights Reserved


DYNAMICS COMPANIONS CONFIGURATION BLUEPRINT

CREATING A BYODB AND CONFIGURING A FULL AND INCREMENTAL ENTITY EXPORT

Creating an Azure SQL Database How to do it…

This will take us to the configuration pane for the SQL server that we are creating.

www.dynamicscompanions.com Dynamics Companions

-9-

www.blindsquirrelpublishing.com © 2018 Blind Squirrel Publishing, LLC , All Rights Reserved


DYNAMICS COMPANIONS CONFIGURATION BLUEPRINT

CREATING A BYODB AND CONFIGURING A FULL AND INCREMENTAL ENTITY EXPORT

Creating an Azure SQL Database How to do it…

We will now need to give our SQL Server a Server name. For this database we will set the Server name to mufifebyodb.

www.dynamicscompanions.com Dynamics Companions

- 10 -

www.blindsquirrelpublishing.com © 2018 Blind Squirrel Publishing, LLC , All Rights Reserved


DYNAMICS COMPANIONS CONFIGURATION BLUEPRINT

CREATING A BYODB AND CONFIGURING A FULL AND INCREMENTAL ENTITY EXPORT

Creating an Azure SQL Database How to do it…

Next we will want to set the Server admin login username that we will be using to authenticate with. For this example we set the Server admin login to the same as the Server name to make it easier to remember.

www.dynamicscompanions.com Dynamics Companions

- 11 -

www.blindsquirrelpublishing.com © 2018 Blind Squirrel Publishing, LLC , All Rights Reserved


DYNAMICS COMPANIONS CONFIGURATION BLUEPRINT

CREATING A BYODB AND CONFIGURING A FULL AND INCREMENTAL ENTITY EXPORT

Creating an Azure SQL Database How to do it…

And then we will want to specify the Password that we will be using to authenticate against the database with.

www.dynamicscompanions.com Dynamics Companions

- 12 -

www.blindsquirrelpublishing.com © 2018 Blind Squirrel Publishing, LLC , All Rights Reserved


DYNAMICS COMPANIONS CONFIGURATION BLUEPRINT

CREATING A BYODB AND CONFIGURING A FULL AND INCREMENTAL ENTITY EXPORT

Creating an Azure SQL Database How to do it…

Next we will want to either create a new Resource group that we will put the SQL Server resource into, or use an exisiting Resource group. To make it easier to track down all the resources used for this project we will create a new Resource group and set it to mufifebyodb.

www.dynamicscompanions.com Dynamics Companions

- 13 -

www.blindsquirrelpublishing.com © 2018 Blind Squirrel Publishing, LLC , All Rights Reserved


DYNAMICS COMPANIONS CONFIGURATION BLUEPRINT

CREATING A BYODB AND CONFIGURING A FULL AND INCREMENTAL ENTITY EXPORT

Creating an Azure SQL Database How to do it…

And finally we will want to add this resource to our workspace so we checked the Pin to dashboard option. After we have done that we can just click on the Create button to get Auzre to configure the resource for us.

www.dynamicscompanions.com Dynamics Companions

- 14 -

www.blindsquirrelpublishing.com © 2018 Blind Squirrel Publishing, LLC , All Rights Reserved


DYNAMICS COMPANIONS CONFIGURATION BLUEPRINT

CREATING A BYODB AND CONFIGURING A FULL AND INCREMENTAL ENTITY EXPORT

Creating an Azure SQL Database How to do it…

That will return us to our workspace and we will see that the resource is queued for creation.

www.dynamicscompanions.com Dynamics Companions

- 15 -

www.blindsquirrelpublishing.com © 2018 Blind Squirrel Publishing, LLC , All Rights Reserved


DYNAMICS COMPANIONS CONFIGURATION BLUEPRINT

CREATING A BYODB AND CONFIGURING A FULL AND INCREMENTAL ENTITY EXPORT

Creating an Azure SQL Database How to do it…

After a couple of seconds, we will have a new SQL server resource and we will be taken to the configuration page. Now we will want to add a new SQL Database to the server. To do this, just click on the + New database link in the menu bar for the SQL server.

www.dynamicscompanions.com Dynamics Companions

- 16 -

www.blindsquirrelpublishing.com © 2018 Blind Squirrel Publishing, LLC , All Rights Reserved


DYNAMICS COMPANIONS CONFIGURATION BLUEPRINT

CREATING A BYODB AND CONFIGURING A FULL AND INCREMENTAL ENTITY EXPORT

Creating an Azure SQL Database How to do it…

This will open up the SQL database configuration form where we will be able to specify the details for our new BYODB database.

www.dynamicscompanions.com Dynamics Companions

- 17 -

www.blindsquirrelpublishing.com © 2018 Blind Squirrel Publishing, LLC , All Rights Reserved


DYNAMICS COMPANIONS CONFIGURATION BLUEPRINT

CREATING A BYODB AND CONFIGURING A FULL AND INCREMENTAL ENTITY EXPORT

Creating an Azure SQL Database How to do it…

Start off by giving the new SQL database a Database name. For this example we will keep everything consistent and give our SQL database a Database name of mufifebyodb.

www.dynamicscompanions.com Dynamics Companions

- 18 -

www.blindsquirrelpublishing.com © 2018 Blind Squirrel Publishing, LLC , All Rights Reserved


DYNAMICS COMPANIONS CONFIGURATION BLUEPRINT

CREATING A BYODB AND CONFIGURING A FULL AND INCREMENTAL ENTITY EXPORT

Creating an Azure SQL Database How to do it…

Next we will want to choose the type of database that we will want to create. If we click on the Pricing for field we will see all of the different SQL options and also how much it will cost us a month to run the SQL server database. By default the Standard database is selected, which (at the time of writing this) is going to cost about $15 a month.

www.dynamicscompanions.com Dynamics Companions

- 19 -

www.blindsquirrelpublishing.com © 2018 Blind Squirrel Publishing, LLC , All Rights Reserved


DYNAMICS COMPANIONS CONFIGURATION BLUEPRINT

CREATING A BYODB AND CONFIGURING A FULL AND INCREMENTAL ENTITY EXPORT

Creating an Azure SQL Database How to do it…

If you are feeling richer then you could select a Premium database, but for this example it’s a little bit too expensive.

www.dynamicscompanions.com Dynamics Companions

- 20 -

www.blindsquirrelpublishing.com © 2018 Blind Squirrel Publishing, LLC , All Rights Reserved


DYNAMICS COMPANIONS CONFIGURATION BLUEPRINT

CREATING A BYODB AND CONFIGURING A FULL AND INCREMENTAL ENTITY EXPORT

Creating an Azure SQL Database How to do it…

So we will select the Standard database template and click on the Apply button. After we have done that we can check the Pin to dashboard option and then click on the OK button.

www.dynamicscompanions.com Dynamics Companions

- 21 -

www.blindsquirrelpublishing.com © 2018 Blind Squirrel Publishing, LLC , All Rights Reserved


DYNAMICS COMPANIONS CONFIGURATION BLUEPRINT

CREATING A BYODB AND CONFIGURING A FULL AND INCREMENTAL ENTITY EXPORT

Creating an Azure SQL Database How to do it…

This will kick off the process to create the Azure SQL database.

www.dynamicscompanions.com Dynamics Companions

- 22 -

www.blindsquirrelpublishing.com © 2018 Blind Squirrel Publishing, LLC , All Rights Reserved


DYNAMICS COMPANIONS CONFIGURATION BLUEPRINT

CREATING A BYODB AND CONFIGURING A FULL AND INCREMENTAL ENTITY EXPORT

Creating an Azure SQL Database How to do it…

After a few seconds we will have a newly minted SQL database that we can start using. Before we move onto the next step we will want to find the Connection string for the database, and to do that we will want to click on the Show database connection string link.

www.dynamicscompanions.com Dynamics Companions

- 23 -

www.blindsquirrelpublishing.com © 2018 Blind Squirrel Publishing, LLC , All Rights Reserved


DYNAMICS COMPANIONS CONFIGURATION BLUEPRINT

CREATING A BYODB AND CONFIGURING A FULL AND INCREMENTAL ENTITY EXPORT

Creating an Azure SQL Database How to do it…

This will open up a page with all of the connection string examples that we will need later on in the process.

www.dynamicscompanions.com Dynamics Companions

- 24 -

www.blindsquirrelpublishing.com © 2018 Blind Squirrel Publishing, LLC , All Rights Reserved


DYNAMICS COMPANIONS CONFIGURATION BLUEPRINT

CREATING A BYODB AND CONFIGURING A FULL AND INCREMENTAL ENTITY EXPORT

Creating an Azure SQL Database Review Congratulations. We now have a SQL server database that we can use to export out our data entities to.

www.dynamicscompanions.com Dynamics Companions

- 25 -

www.blindsquirrelpublishing.com © 2018 Blind Squirrel Publishing, LLC , All Rights Reserved


Turn static files into dynamic content formats.

Create a flipbook
Creating a BYODB and Configuring a Full and Incremental Entity Export by Dynamics Companions - Issuu