Tuesday, November 15, 2016

Power BI connecting to SQL Server 2016 via OLE DB

October update of Power BI allows you to connect to SQL Server 2016 using OLE DB Connectivity.

This post shows you how in just a few steps.

Launch Power BI from its shortcut on the desktop as shown. It may message you about auto recovery of files. Do not worry about it.


Click Get Data from the toolbar. Get data page is opened displaying all the data ssources from which you retrieve your data.


Click on 'Other' to reveal data sources contained therein as shown.


Now click on OLE DB and click Connect at the bottom to open the next dialog as shown.


At this step you are going to build the part of a connection string with non-credential properties.

Click Build and the Data Link Properties window gets displayed wherein you find a  OLE DB Providers for various types of data sources.


In the present case pick SQL Server Native Client 11.0 as native clients are generally faster. After highlighting SQL Server Native Client 11.0 click Next.

You need to select by entering the name of the server. Click on the handle tor eveal all SQL Servers as shown.


Click HOEDENTAK8\OHANA which is a named instance pf SQL Server 2016. Click Use Windows NT Integrated security for the log information. For the third items click on the handle for the database selection as shown.


Choose AdventureWorks2014 and click Test Connection. You should get the following message.


Click OK and you get returned to the From OLE DB window displaying the connection string as shown.


Notice that although you provided authentication information it was not registered (probably by design).

Click OK. The Navigator opens as shown.


You can choose table or tables to continue. Here it is looking at the Address for Person as shown.


This completes using the OLE DB connectivity using the Native Provider. It will probably allow you to create reports etc.

Two things bother me, one is the authentication and the other relates to the objects exposed. I did choose AdventureWorks2014 but it exposes everything on the server. Should it be like this?

PowerShell Pro Tools is a Visual Studio Community 2017 extension that you can try free

I see there is at least one extension, PowerShell Pro Tools that you can download. You can find it in the Visual Studio Community 2017...