无法从Visual Studio 2015 RC中的MySQL数据库更新EntityFramework模型 [英] Unable to update EntityFramework models from MySQL database in Visual Studio 2015 RC

查看:127
本文介绍了无法从Visual Studio 2015 RC中的MySQL数据库更新EntityFramework模型的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

几个月前,我的组织从Visual Studio 2013升级到了Visual Studio 2015 RC,我们只是现在才尝试从MySQL数据库中更新一些现有的"db-first" EntityFramework模型.这样做时,我们收到以下错误.

尝试从数据库更新时,发生类型为'System.ArgumentException'的异常.异常消息是:'无法将运行时连接字符串转换为其等效的设计时.对于提供程序'MySql.Data.MySqlClient',未安装使Visual Studio出于设计目的与数据库进行通信所需的库(DDEX提供程序).

对此错误的快速SO搜索产生了从2013年11月开始的此结果(特别是针对VS 2013)...

显然MySql和Visual Studio 2013尚不能一起使用.

以下是MySql论坛上的链接: http://forums.mysql.com/read.php?174,594798,600466#msg-600466

您可能需要等待MySql连接器的下一个发行版.

这是否意味着这可能是一个可比较的问题,我们只需要等待它,直到有与VS 2015兼容的新MySql.Data客户端可用?还是可能是其他原因造成的(也许是VS 2015 RC中的错误)?

我们正在使用Entity Framework(6.1.3),MySql.Data(6.9.6)和MySql.Data.Entity(6.9.6)的最新稳定版本.

尤其是想知道是否有人在VS 2015 RC上偶然发现了此问题.

解决方案

对我有用的是更新Visual Studio插件,可在这里找到: http://dev.mysql.com/downloads/windows/visualstudio/

My organization upgraded from Visual Studio 2013 to Visual Studio 2015 RC a couple months ago, and we only just now attempted to update some of our existing "db-first" EntityFramework models from our MySQL database. When doing so, we received the following error.

An exception of type 'System.ArgumentException' occurred while attempting to update from the database. The exception message is: 'Unable to convert runtime connection string to its design-time equivalent. The libraries required to enable Visual Studio to communicate with the database for design purposes (DDEX provider) are not installed for provider 'MySql.Data.MySqlClient'.

A quick SO search for this error produced this result from November of 2013 (specifically in reference to VS 2013)...

Apparently MySql and Visual Studio 2013 don't work together yet.

Here is a link on the MySql forums: http://forums.mysql.com/read.php?174,594798,600466#msg-600466

You'll probably need to wait for the next release of the MySql connector.

Does that mean this is likely a comparable issue, and we just have to wait it out until a new MySql.Data client is available that is compatible with VS 2015? Or is it possible that some other cause is to blame (perhaps a bug in VS 2015 RC)?

We're on the latest stable versions of Entity Framework (6.1.3), MySql.Data (6.9.6) and MySql.Data.Entity (6.9.6).

Especially curious to hear if anyone else has stumbled across this issue with VS 2015 RC in particular.

解决方案

What worked for me was to update the visual studio plugin, available here: http://dev.mysql.com/downloads/windows/visualstudio/

这篇关于无法从Visual Studio 2015 RC中的MySQL数据库更新EntityFramework模型的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆