There is quite a nice cheat sheet on migrating from System.Data.SqlClient to Microsoft.Data.SqlClient here that hopefully explains the change : https://github.com/dotnet/SqlClient/blob/main/porting-cheat-sheet.md#functionality-changes
Relevant part is below: