如何找出领域最大长度的实体框架是.NET 4? [英] How to find out field maximum length in Entity Framework in .NET 4?
本文介绍了如何找出领域最大长度的实体框架是.NET 4?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
根据这个的问题,有一个在EF没有内置的方式V1找出一个字段的长度。是否有一个的内置的方法,这样做的实体框架附带.NET 4,如果是这样 - 怎么样?
According to this question, there's no built-in way in EF v1 to figure out the length of a field. Is there a built-in way to do so in the Entity Framework that ships with .NET 4, if so - how?
推荐答案
有没有新的方式来访问EF 4.0属性的长度。您还必须走过去的元数据 - 在你引用问题公认的答案显示
There is no new way to access the length of a property in EF 4.0. You still have to walk over the metadata - as shown in the accepted answer on the question you reference.
亚历克斯·詹姆斯
前EF团队成员!
这篇关于如何找出领域最大长度的实体框架是.NET 4?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文