What I'm trying to do:
- Connecting HANA db from .Net Core application. (Windows environment)
What I did:
- Downloaded and installed HANA Client for windows. Installed using "hdbinst.exe" from the folder "hdb_client_windows_x86_64" I got it.
- Created a NuGet package for the file - "Sap.Data.Hana.Core.v2.1.dll" from the path: C:\Program Files\sap\hdbclient\dotnetcore\v2.1
- Installed this file in to my sample .Net Core 2.1 project thru NuGet package manager.
What I'm experiencing:
- Warning 1 --> Warning NU1701. Package 'SAP.HANADBClient.NetCore 2.1.0' was restored using '.NETFramework,Version=v4.6.1' instead of the project target framework '.NETCoreApp,Version=v2.1'. This package may not be fully compatible with your project.
- Warning 2 --> Warning MSB3270. There was a mismatch between the processor architecture of the project being built "MSIL" and the processor architecture of the reference "C:\Users\XXXXX.nuget\packages\sap.hanadbclient.netcore\2.1.0\lib\Sap.Data.Hana.Core.v2.1.dll", "AMD64". This mismatch may cause runtime failures. Please consider changing the targeted processor architecture of your project through the Configuration Manager so as to align the processor architectures between your project and references, or take a dependency on references with a processor architecture that matches the targeted processor architecture of your project.
- Similar case for .Net Core 2.2 project
What I looked around:
- I did a search in the web and saw few members had already shared this kind of issue (.Net core with HANA integration). But saw this post saying that the issue got resolved. But was it good? not sure.
- Even this post says HANA supports .Net Core.
- Did search in the web, but could not find the solution.
What I'm looking for:
- Why am I getting these two warnings?
- Will it give any issues later on - (prod runtime..)
- Particularly - 2nd warning - why it's looking for "Processor architecture", and how to resolve this.
Can I request any one of you to help me out on this effort. Please let me know still additional details are needed.
Thanks in advance.