Micorsoft.Data.SqlClient not working with Microsoft.Aspnet.Identity connections
See original GitHub issueHi there,
I need to use Micorsoft.Data.SqlClient provider now in my existing project which was using System.Data.SqlClient DB provider.
We have added the library dll’s from Nuget for Microsoft.Data.SqlClient already and also added the following lines in machine.config
<system.data> <DbProviderFactories> <add name="SqlClient Data Provider" invariant="Microsoft.Data.SqlClient" description=".Net Framework Data Provider for SqlServer" type="Microsoft.Data.SqlClient.SqlClientFactory, Microsoft.Data.SqlClient" /> </DbProviderFactories> </system.data>
Our web.config for connection string is using now:
providerName=“Microsoft.Data.SqlClient”
Normal DB connection seems working fine with Microsoft.Data.SqlClient But,
we are getting error while using Microsoft.AspNet.Identity.Owin in line as:
AppUser = UserManager.FindByName(uname);
“The ADO.NET provider with invariant name ‘Micorsoft.Data.SqlClient’ is either not registered in the machine or application config file, or could not be loaded. See the inner exception for details.”
Inner Exception as: “{“Unable to find the requested .Net Framework Data Provider. It may not be installed.”}”.
Kindly suggest us the solution for this issue.
Thanks
Issue Analytics
- State:
- Created 3 years ago
- Comments:12 (7 by maintainers)
I will possible test these changes next monday on 21st december 2020
closing due to inactivity. Feel free to reopen the issue if it still remains.