Project works correctly on SqlClient 4.4.0. When we update to Microsoft.Data.SqlClient 5.0.1, get this error:
> System.TypeLoadException: Could not load type 'Microsoft.Data.SqlClient.Server.IBinarySerialize' from assembly 'Microsoft.Data.SqlClient,
> Version=5.0.0.0, Culture=neutral, PublicKeyToken=23ec7fc2d6eaa4a5'.****
>
Problem is caused by a breaking change listed in:
https://github.com/dotnet/SqlClient/blob/main/release-notes/5.0/5.0.0.md
IBinarySerialize has been moved to package Microsoft.SqlServer.Server 1.0.0.
I'm working on a PR now to fix this.
I took a fork and made a 5.0 compatible version at https://github.com/alansingfield/Microsoft.SqlServer.Types
https://www.nuget.org/packages/alansingfield.Microsoft.SqlServer.Types
Oops - didn't spot that one! I must have had the exclude prerelease flag turned on in NuGet.
I've replaced the reference and it's all working. I'll deprecate my fork as it's no longer needed.
Thanks for your help!
Yup p/invoke is smart on .net and will call SqlServerSpatial160.so on Linux. Check the runtimes folder in the nuget package to get an idea of platforms currently supported. They also confirmed iOS and Android support is coming…