如何在实体框架中使用代码第一个新数据库连接到数据库 [英] How to connect to database using code first new database in entity framework

查看:59
本文介绍了如何在实体框架中使用代码第一个新数据库连接到数据库的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述



我在一个样本中创建了一个新数据库,首先使用代码。现在在一个新的示例程序中,我想连接到这个数据库并在数据库中显示数据。请告诉我如何通过编码连接到这个数据库。尽快回复。

hi ,
I have created a new database in one sample, using code first . Now in a new sample program, i want to connect to this database and display data in database. Please tell me how to connect to this database through coding. Reply ASAP.

推荐答案

这里,以下内容可以帮到你: MSDN:代码优先到新数据库 [ ^ ]
Here, following should help you out: MSDN: Code First to a New Database[^]


这篇关于如何在实体框架中使用代码第一个新数据库连接到数据库的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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