反正在.NET Core中使用Entity Framework吗?

Mig*_*ada 6 c# asp.net entity-framework .net-core

我刚刚改用新的ASP.NET 5平台.我使用visual studio代码作为我的默认IDE,并使用DNX执行..NET Core现在默认情况下,但我需要切换到.NET Framework,我想引用System.Data.Entity命名空间或TodoContext类.

无论如何在.NET Core中使用EF?

这就是我现在正在做的事情. 在此输入图像描述

Vic*_*aci 18

EntityFramework in System.Data是版本6.如果要使用.NET Core,则需要切换到不再存在于System.Data但位于EntityFramework.*nuget包中的EF 7 .

这是一个例子:https://github.com/aspnet/MusicStore/blob/master/src/MusicStore/project.json#L15

  • 该链接已断开 (3认同)