Philipp Sumi
Philipp Sumi

Reputation: 987

Microsoft.SqlServer.Types: Are native libries for SQL Server preinstalled on Azure?

I just upgraded my app to use the latest Microsoft.SqlServer.Types package v14 from v13. This resulted in an well-documented runtime error. The reason here would be missing native libraries:

Spatial types and functions are not available for this provider because the assembly 'Microsoft.SqlServer.Types' version 10 or higher could not be found

The Nuget package also contains the native DLLs that were missing, so I could theoretically copy them to my bin folder and load them through my code, but:

My current assumption would be that I got the v13 binaries with my local SQL install, and on Azure, those binaries (both v13 / v14) are preinstalled.

However, when googling a bit about the issue, most developers have the opposite problem of things not working on Azure due to the missing libs, so I wonder whether not going the manual route might be dangerous with regards to Azure deployments. If anybody had some insight here, that would be awesome!

Upvotes: 0

Views: 417

Answers (1)

Brando Zhang
Brando Zhang

Reputation: 28067

As far as I know, the azure web service install the SQL server SDK version is 9.0 - 13.0. So you need install 14.0 by yourself.

You could find the dll in the kudu console in your web service.

D:\Program Files (x86)\Microsoft SQL Server\130\SDK\Assemblies> 

To open the kudu you could refer to below steps:

1.Find the Advanced Tools in DEVELOPMENT TOOLS click go.

enter image description here

2.Click dubug console's cmd.

enter image description here

3.Find the path. Notice: You need firstly type cd.. to locate the root path.

You could find the Microsoft.SqlServer file as below:

enter image description here

Upvotes: 1

Related Questions