gpt4 book ai didi

mysql - 配置错误 - 无法识别的属性 'name'/无法找到请求的 .Net Framework 数据提供程序。它可能没有安装

转载 作者:可可西里 更新时间:2023-11-01 07:34:12 24 4
gpt4 key购买 nike

尝试在实时 Web 应用程序中访问我的数据库时出现错误:

Server Error in '/' Application.

Configuration Error

Description: An error occurred during the processing of a configuration file required to service this request. Please review the specific error details below and modify your configuration file appropriately.

Parser Error Message: Unrecognized attribute 'name'.

Source Error:

An application error occurred on the server. The current custom error settings for this application prevent the details of the application error from being viewed remotely (for security reasons). It could, however, be viewed by browsers running on the local server machine.

Source File: C:\home\site\wwwroot\web.config Line: 115

第115行所在的我的web配置:

<entityFramework>
<defaultConnectionFactory type="System.Data.Entity.Infrastructure.LocalDbConnectionFactory, EntityFramework">
<parameters>
<parameter value="mssqllocaldb" />
</parameters>
</defaultConnectionFactory>
<providers>
<provider invariantName="System.Data.SqlClient" type="System.Data.Entity.SqlServer.SqlProviderServices, EntityFramework.SqlServer" />
<provider invariantName="MySql.Data.MySqlClient" type="MySql.Data.MySqlClient.MySqlProviderServices, MySql.Data.Entity.EF6, Version=6.8.3.0, Culture=neutral, PublicKeyToken=c5687fc88969c44d"></provider>
</providers>
</entityFramework>
<system.data>
<DbProviderFactories>
<remove invariant="MySql.Data.MySqlClient" name="MySQL Data Provider" /> // Line: 115
<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.9.9.0, Culture=neutral, PublicKeyToken=c5687fc88969c44d" />
<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>

当我从该行中删除:name="MySQL Data Provider" 时,我只会收到另一个错误并绕圈子。

此外,当我刷新页面并删除 name 部分时,我得到:

Unable to find the requested .Net Framework Data Provider. It may not be installed.

非常感谢任何帮助。

最佳答案

我有一个非常相似的问题,但对我没有任何帮助。我通过将 .NET Framework 版本从 4.5.2 更改为 4.5 来修复它。看看这个 article.

关于mysql - 配置错误 - 无法识别的属性 'name'/无法找到请求的 .Net Framework 数据提供程序。它可能没有安装,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/42162456/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com