EF 4.1 RC Many to many relationship in EF CF

后端 未结 2 1036
滥情空心
滥情空心 2021-02-10 09:43

I have two entities with many to many relationship like this:

class author
{
  public int AuthorID{get;set;}
  public string Name{get;set;}
  public virtual ICol         


        
2条回答
  •  伪装坚强ぢ
    2021-02-10 10:27

    I don't think EF allows you to have a separate Id in many-to-many junction tables.

    The alternative is just mapping BookAuthor as an entity.

    On a side note, NHibernate supports this construct using an idbag

提交回复
热议问题