从代码优先的流畅映射生成数据库模式(没有edmx) [英] Generating a database schema from code-first fluent mappings (no edmx)

查看:80
本文介绍了从代码优先的流畅映射生成数据库模式(没有edmx)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

是否可以先从代码中的流畅映射生成数据库模式(ctp 4)?  

Is it possible to generate the database schema from fluent mappings in code first (ctp 4)?  

 

非常感谢任何帮助。

 

 

推荐答案

是的,这是使用Code First的主要方案之一。本演练演示Code First生成模式,包括使用Fluent API来影响模式的形状;

http://blogs.msdn.com/ b / adonet / archive / 2010/07/14 / ctp4piwalkthrough.aspx

Yes absolutely, this is one of the primary scenarios for using Code First. This walkthrough shows Code First generating a schema, incl the use of the Fluent API to affect the shape of the schema; http://blogs.msdn.com/b/adonet/archive/2010/07/14/ctp4piwalkthrough.aspx

~Rowan


这篇关于从代码优先的流畅映射生成数据库模式(没有edmx)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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