EntityFramework.dll vs System.Data.Entity.dll - ambiguity

Interestingly, EntityFramework.dll and System.Data.Entity.dll have something in common and that they are different? My project references System.Data.Entity.dll (June CTP) to use the first code model, and everything works fine.

Now I want to use the First First Migrations tool, and it needs to add EntityFramework.dll, which I also need to add to my project. However, when both libraries are mentioned (EntityFramework.dll and System.Data.Entity.dll), I get a lot of compiler errors, claiming that some classes are defined in both libraries.

When I remove EntityFramework.dll, the project compiles again, but I cannot use Migrations. When it only refers to EntityFramework.dll, I get complier errors telling me that some classes were not found (for example, a spatial data type).

What should I do in this situation? Thank you in advance!

+13
entity-framework ef-code-first
Oct 25 2018-11-21T00:
source share
1 answer

The System.Data.Entity.dll version "4.2.0.0" (June CTP 2011) contains everything: from EFv4.0 and EFv4.1 = both the ObjectContext API and the DbContext API + new features, but this is probably the only version for a long the time that will combine the two APIs in the same assembly. This CTP is dead. The new kernel features will be ported to .NET 4.5, and the DbContext API will still be shipped as a separate NuGet package containing EntityFramework.dll. Everything is described here .

Code transitions depend on EFv4.1 Update 1 and its EntityFramework.dll. They are not compatible with the June CTP, and this is described directly in the installation notes or premises = you cannot use them with the June CTP.

+16
Oct 26 '11 at 8:00
source share



All Articles