Reputation: 880
I want ASP.NET 5 with EF7 and some old EF 6.1.3 in some subassemblies.
I am upgrading an older web project to ASPNET5, and I am using VS2015.
I have created a plain template demo project and it works as it is on its own.
However, as soon I added some .NET 4.0 with EF 6.1.3 projects to the solution, I got this error
CS1061 'EntityFrameworkServicesBuilder' does not contain a definition for 'AddSqlServer' and no extension method 'AddSqlServer' accepting a first argument of type 'EntityFrameworkServicesBuilder' could be found (are you missing a using directive or an assembly reference?) lic5.DNX 4.5.1 C:\data3\ssc\ssc.master\license\lic5\Startup.cs 55
In the project file, I have
"dependencies": {
"EntityFramework.SqlServer": "7.0.0-beta5",
"EntityFramework.Commands": "7.0.0-beta5",
(Why not upgrade to EF7 everywhere? Then I need to use .NET 4.5, and I have many old .NET 4.0 dlls for which I am not responsible, and which needs to continue to be .NET 4.0.)
Upvotes: 2
Views: 724
Reputation: 2971
If I'm reading it right, the EF team decided within the last 7 days (and today!) to do this very thing, partly by renaming EntityFramework.SQLServer to EntityFramework.MicrosoftSQLServer. See https://github.com/aspnet/EntityFramework/issues/3270 for more details (though there aren't really that many).
Upvotes: 4