MySQL数据源向导无法在Visual Studio 2017上运行

问题描述 投票:3回答:1

我在同一台PC上安装了Visual Studio 2017社区,并安装了MySQL Community 8.0.12。它还配备了Visual Studio 2.0.5和MySQL Connector / NET 8.0.12的MySQL。

现在,在Visual Studio中使用DataSource向导。我能够测试与我的服务器的连接,并选择我想要添加到TablesDataSet

但是当我点击Finish时,出现以下错误:

"Some updating commands could not be generated automatically. The database returned the following error: Unexpected Error"

接下来是另一个错误日志:

"Could not retrieve schema information for table or view [tablename]"

对于我想添加的每个Table

我已经查看了有关上述错误的一些信息,但到目前为止,他们正在谈论旧版本的Visual Studio和MySQL。任何帮助将不胜感激。谢谢。

mysql database visual-studio visual-studio-2017 connector
1个回答
2
投票

因此,经过一些调整并查看MySQL官方网站后,我将我的Connector / NET降级到版本6.9.8,并将MySQL for Visual Studio降级为1.2.7版本

现在,DataSource能够获取表定义等。

每当按下DataSource向导中的“FINISH”按钮时,仍然会出现一个小错误,显示“无法添加关系指定的强制转换无效”。

但是,此错误不会阻止创建和使用DataSource。我仍然不确定是什么原因引起了这个错误。

© www.soinside.com 2019 - 2024. All rights reserved.