Re: Entity Framework 6 support
Posted by: Darlington Adibe
Date: November 01, 2013 09:30PM

Hi Roberto,

Is it possible to have a detail example of how to use EF6 with .NET MVC 4, I have not been able to use any EF with any off the version.

The closest I got is with the alpha release of Connector/NET Version 6.8.0.0 with EF6, but then when I execute

PM> Add-Migration InitialCreate

I get the following error

System.Runtime.Serialization.SerializationException: 'Type is not resolved for member 'MySql.Data.MySqlClient.MySqlException,MySql.Data, Version=6.8.0.0, Culture=neutral, PublicKeyToken=c5687fc88969c44d'

I have searched the net and just can't find any Code-First example that works, Please if you could post a very simple MVC4 sample with EF6 using Connector/NET it will be great as I noticed from my search its giving alot of people like my much trouble.

Here is my web.config

<system.data>
<DbProviderFactories>
<clear />
<remove invariant="MySql.Data.MySqlClient" />
<add name="MySql.Data.MySqlClient" invariant="MySql.Data.MySqlClient" description=".Net Framework Data Provider for MySQL"
type="MySql.Data.MySqlClient.MySqlClientFactory, MySql.Data, Version=6.8.0.0, Culture=neutral, PublicKeyToken=c5687fc88969c44d" />
</DbProviderFactories>
</system.data>
<entityFramework>
<defaultConnectionFactory type="MySql.Data.MySqlClient.MySqlClientFactory, MySql.Data, Version=6.8.0.0, Culture=neutral, PublicKeyToken=c5687fc88969c44d" />
<providers>
<provider invariantName="MySql.Data.MySqlClient" type="MySql.Data.MySqlClient.MySqlProviderServices, MySql.Data.Entity.EF6, Version=6.8.0.0, Culture=neutral, PublicKeyToken=c5687fc88969c44d" />
</providers>
</entityFramework>

Options: ReplyQuote


Subject
Written By
Posted
August 28, 2013 10:19PM
Re: Entity Framework 6 support
November 01, 2013 09:30PM
January 05, 2014 05:34PM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.