close

源自於這兩篇文章
(2019/5/8)   https://devblogs.microsoft.com/dotnet/introducing-the-new-microsoftdatasqlclient/
(FAQ)          https://github.com/dotnet/SqlClient/wiki/Frequently-Asked-Questions

 

Microsoft.Data.SqlClient 與 System.Data.SqlClient 

通常在 .NET Framework裡面會見到的命名空間(NameSpace)
大多以 System.開頭。
但微軟也會推出同名,但以 Microsoft.開頭的命名空間。(我自己描述的話,就是原廠的改版、擴充、新功能)

 

第一篇文章講得就是這件事 - Introducing the new Microsoft.Data.SqlClient
https://devblogs.microsoft.com/dotnet/introducing-the-new-microsoftdatasqlclient/

這篇文章是由SqlClient和SQL Server Tools的專案經理Vicky Harp寫的。簡介如下:

** In .NET Framework, versions are installed globally in Windows. 
(通常跟作業系統、.NET Framework "完整版"整合一起)

** In .NET Core, an application can pick a specific SqlClient version and ship with that. 
(可以搭配特定的SqlClient版本並交付)(透過Nuget取得這個套件)
Wouldn’t it be nice if the .NET Core model of SqlClient delivery worked for .NET Framework, too?

 

新功能 Always Encrypted需搭配 SQL Server 2016。
新功能 Enclave需搭配 SQL Server 2019。

 

如果您使用ORM相關軟體,請注意:

Keep in mind that object-relational mappers such as EF Core, EF 6, or Dapper, and other non-Microsoft libraries, haven’t yet(尚未) made the transition to the new provider, so you won’t be able to use the new features through any of these libraries. 

 

================================

其他的FAQ,這裡解釋得很清楚:
https://github.com/dotnet/SqlClient/wiki/Frequently-Asked-Questions

================================

6. Microsoft.Data.SqlClient支持的最小目標(target)框架是什麼?
      支持.NET Framework(.NET完整版) 4.6及更高版本,
      .NET Core 2.1及更高版本      以及.NET Standard 2.0及更高版本。 
      如果要支持早期(以前版本)的Framework,請繼續使用System.Data.SqlClient。

9.  這是重寫SqlClient嗎?
      不。將有 "兩個"代碼庫
      (一個用於.NET Framework中的System.Data.SqlClient,一個用於.NET Core中的System.Data.SqlClient)整合到一個套裝軟體中發佈。
      Microsoft.Data.SqlClient下面仍然存在不同的代碼庫,它們被編譯到不同的目標 (targets)中。 ......
      .NET Core代碼庫編譯到包中支持.NET Core和.NET Standard目標的二進製文件中。......

      我的註解:您要安裝"新版" .NET Framework到"舊版"Visual Studio裡面,
                       通常要找一套名為「 target(目標套件)」的軟體
                       例如
https://dotblogs.com.tw/mis2000lab/2016/08/24/dotnet_462_download

      長期目標是合併代碼庫,但我們目前還沒做到。

arrow
arrow

    MIS2000 Lab 發表在 痞客邦 留言(0) 人氣()