简体   繁体   English

与Visual Studio 2013 Preview的MySQL数据库连接

[英]MySQL Database Connection With Visual Studio 2013 Preview

我正在使用Visual Studio 2013 Preview,但是在“选择数据源”对话框窗口中找不到MySQL数据库,我甚至安装了最新版本的MySQL连接器以及windows MySQL安装程序(为Visual Studio获取MySQL插件)但是没有任何改变,我不得不回到VS 2012 Ultimate,我只是想知道2013预览版是否有特殊的MySQL连接器?

I am using Visual Studio 2013 Ultimate and I got it working with the Mysql Visual Studio 1.1.1 beta plugin. 我正在使用Visual Studio 2013 Ultimate,我使用了Mysql Visual Studio 1.1.1 beta插件。

Requirements: 要求:

  • Windows OS 7 or later. Windows OS 7或更高版本。
  • Visual Studio 2010, 2012 or 2013 professional or higher version. Visual Studio 2010,2012或2013专业版或更高版本。
  • Connector/Net 6.8.1 beta or higher version to check the Connector/Net & Entity Framework features. Connector / Net 6.8.1 beta或更高版本,用于检查Connector / Net&Entity Framework功能。 (download at: http://dev.mysql.com/downloads/connector/net/ on the development releases). (关于开发版本,请访问: http//dev.mysql.com/downloads/connector/net/ )。

Download: 下载:

https://cdn.mysql.com/Downloads/MySQLInstaller/mysql-visualstudio-plugin-1.1.1.msi https://cdn.mysql.com/Downloads/MySQLInstaller/mysql-visualstudio-plugin-1.1.1.msi

You can find the latest here (v1.2.3): 你可以在这里找到最新的(v1.2.3):

http://dev.mysql.com/downloads/windows/visualstudio/ http://dev.mysql.com/downloads/windows/visualstudio/

Source: 资源:

http://forums.mysql.com/read.php?174,601041,601041#msg-601041 http://forums.mysql.com/read.php?174,601041,601041#msg-601041

I use Visual Studio 2012. Correct process of installing MySql will help you avoid any such error. 我使用Visual Studio 2012.正确安装MySql的过程将帮助您避免任何此类错误。 At least this is what i did. 至少这就是我所做的。

  1. Download and install visual studio 2012 下载并安装visual studio 2012
  2. Download and install mysql-installer-community-5.6.17.0 下载并安装mysql-installer-community-5.6.17.0
  3. Download and install mysql-connector-net-6.8.3 下载并安装mysql-connector-net-6.8.3
  4. Download and install mysql-visualstudio-plugin-1.1.1 下载并安装mysql-visualstudio-plugin-1.1.1
  5. Order is important and each item too. 订单很重要,每个项目也很重要。
  6. Open Visual Studio and Create new project 打开Visual Studio并创建新项目
  7. Add reference of MySql.Data in solution explorer after right clicking the project name 右键单击项目名称后,在解决方案资源管理器中添加MySql.Data的引用
  8. View server explorer 查看服务器资源管理器
  9. Add new connection and fill the spaces correctly 添加新连接并正确填充空格
  10. At the top of your code, add using MySql.Data.MySqlClient 在代码的顶部,使用MySql.Data.MySqlClient添加

对于Visual Studio 2013,安装“MySQL for Visual Studio 1.2.8”

I've not tested it yet, and it's for VS2012 (and I guess it's the same for VS2013) but the following link may help: 我还没有测试过它,它适用于VS2012(我想VS2013也是如此),但以下链接可能有所帮助:

http://blog.nwoolls.com/2012/07/25/registering-missing-data-providers-with-visual-studio-2012/ http://blog.nwoolls.com/2012/07/25/registering-missing-data-providers-with-visual-studio-2012/

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM