1.安装 mysql connector net 6.9.9  https://dev.mysql.com/downloads/file/?id=463758 和mysql for visual studio 1.2.6  https://dev.mysql.com/downloads/windows/visualstudio/,在EF框架中使用mysql作为数据源时需要安装mysql-for-visualstudio这个工具驱动,否则VS建立实体模型中没有选择mysql为数据源的选项.

ef使用dbfirst方式连接mysql

2.nuget安装  Install-Package MySql.Data.Entity -Version 6.9.9   (版本号6.9.9和mysql connector net 6.9.9版本号一致)

ef使用dbfirst方式连接mysql

3.添加ado.net实体数据模型

ef使用dbfirst方式连接mysql

 

ef使用dbfirst方式连接mysql

相关文章:

  • 2022-12-23
  • 2021-12-16
  • 2022-12-23
  • 2021-09-03
  • 2022-01-18
  • 2022-12-23
猜你喜欢
  • 2022-12-23
  • 2021-11-28
  • 2021-05-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
相关资源
相似解决方案