6
I am developing a web project in VS 2012, this application connects with a Mysql database developed in Mysqlworkbench 60 CE with Mysql server 5.6, I have referenced in the project the Entityframework version 6.1, Mysql.ConnectorNET.Data 6.8.3.2, mysqlconnector.Net. Entity 6.8.3.2,mysql. data, mysql.data.entitie, myslq.web all in version 6.8.3.
When I run my project a test class that performs data entry in the capture database and returns me the following error:
Unrecognized 'name' attribute. (C: Desktop Users Simulationvalues Web interface.config line 17)
I believe the error is in the webconfig below:
<?xml version="1.0" encoding="utf-8"?>
<!--
For more information on how to configure your ASP.NET application, please visit
http://go.microsoft.com/fwlink/?LinkId=169433
-->
<configuration>
<configSections>
<section name="entityFramework" type="System.Data.Entity.Internal.ConfigFile.EntityFrameworkSection, EntityFramework, Version=6.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" requirePermission="false" />
<!-- For more information on Entity Framework configuration, visit http://go.microsoft.com/fwlink/?LinkID=237468 -->
</configSections>
<system.web>
<compilation debug="true" targetFramework="4.5" />
<httpRuntime targetFramework="4.5" />
</system.web>
<system.data>
<DbProviderFactories>
<remove name="MySQL Data Provider" invariant="MySql.Data.MySqlClient" />
<add name="MySQL Data Provider" invariant="MySql.Data.MySqlClient" description=".Net Framework Data Provider for MySQL" type="MySql.Data.MySqlClient.MySqlClientFactory, MySql.Data, Version=6.8.3.0, Culture=neutral, PublicKeyToken=c5687fc88969c44d" />
</DbProviderFactories>
</system.data>
<entityFramework>
<defaultConnectionFactory type="System.Data.Entity.Infrastructure.LocalDbConnectionFactory, EntityFramework">
<parameters>
<parameter value="v11.0" />
</parameters>
</defaultConnectionFactory>
<providers>
<provider invariantName="System.Data.SqlClient" type="System.Data.Entity.SqlServer.SqlProviderServices, EntityFramework.SqlServer" />
</providers>
</entityFramework>
<connectionStrings>
<add name="bancotccEntities" connectionString="metadata=res://*/bancotcc.csdl|res://*/bancotcc.ssdl|res://*/bancotcc.msl;provider=MySql.Data.MySqlClient;provider connection string="server=localhost;user id=root;password=tcc2012;persistsecurityinfo=True;database=bancotcc"" providerName="System.Data.EntityClient" />
</connectionStrings>
<runtime>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly>
<assemblyIdentity name="EntityFramework" publicKeyToken="b77a5c561934e089" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-6.0.0.0" newVersion="6.0.0.0" />
</dependentAssembly>
</assemblyBinding>
</runtime>
</configuration>
@Sunstreaker kkkk cool ... !!!
– user6026
Hello, thanks for replying Harry Potter, I did what you suggested but I ended up in another error see below: bancotcc.ssdl(2,2) : error 0152: No Entity Framework Provider found for the ADO.NET Provider with invariant name 'Mysql.Data.Mysqlclient'. Make sure the Provider is Registered in the 'entityFramework' Section of the application config file. See http://go.microsoft.com/fwlink/? Linkid=260882 for more information
– user9090
<system.data> <Dbproviderfactories> <remove name="Mysql Data Provider" invariant="Mysql.Data.Mysqlclient" /> <add name="Mysql Data Provider" invariant="Mysql.Data.Mysqlclient" Description=". Net Framework Data Provider for Mysql" type="Mysql.Data.Mysqlclient.Mysqlclientfactory, Mysql.Data, Version=6.8.3.0, Culture=neutral, Publickeytoken=c5687fc88969c44d" /> </Dbproviderfactories>
– user9090
HI, thanks for the help and patience, but there was a </system.data> in the above section
– user9090
Not without the remove it day that already exists the value for Data.MySqlClient.Mysqlclientfactory,
– user9090
No Entity Framework Provider found for the ADO.NET Provider with invariant name 'Mysql.Data.Mysqlclient'. Make sure the Provider is Registered in the 'entityFramework' Section of the application config file. See http://go.microsoft.com/fwlink/? Linkid=260882 for more information
– user9090
I’m sorry, but I’m new to the site
– user9090