多态协会的​​LINQ to SQL [英] Polymorphic associations in LINQ to SQL

查看:122
本文介绍了多态协会的​​LINQ to SQL的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

是否的LINQ to SQL提供开箱即装即用的多态关联的Ruby on Rails的活动记录呢?如果没有,有没有什么办法来手动映射这些关联?

Does LINQ to SQL provide out-of-the-box polymorphic associations as ruby on rails active record does? If not, is there any workaround to manually map those associations?

推荐答案

同意。我发现这样做也没有使用设计也不是由手工追加类没有可能的方式/方法的属性。而且不可能有外键约束的多态关联。我放弃了这个选项,谢了。

Agreed. I found no possible way of doing this nor using the designer nor by hand appending class/method attributes. Moreover is not possible to have foreign key constraints for polymorphic associations. I discarded this option, thanks.

这篇关于多态协会的​​LINQ to SQL的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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