Multiple foreign keys to the same table

后端 未结 4 428
伪装坚强ぢ
伪装坚强ぢ 2021-02-04 16:54

I have a reference table with all sorts of controlled value lookup data for gender, address type, contact type, etc. Many tables have multiple foreign keys to this reference tab

4条回答
  •  遥遥无期
    2021-02-04 17:32

    In VS2010 You can actually rename the properties for parent and child in the view. It is a bit hidden though.

    1. In the dbml viewer select the relationship that bothers you.
    2. In the Properties grid you will have two rows Child and Parent Property.
    3. Expand them there you can change the Name of the property

    More details can be found here: http://weblogs.asp.net/scottgu/archive/2007/05/29/linq-to-sql-part-2-defining-our-data-model-classes.aspx

    Which is where I got it from.

提交回复
热议问题