Have you an idea about from where NH can know/read to write in the FK ? 2010/2/17 Alex McMahon <[email protected]>
> I have a legacy database that I'm restricted from changing. I have 2 > related tables that both have a foreign key to the same 3rd table. In > my application I'd rather not have this relationship repeated on both > classes. But when I don't map this relationship for both classes I get > problems as NHibernate does not put the foreign key in the database. > > I'd like it to be like this: > TableA: > TableBId > TableCId > (other fields) > > TableB: > TableCId > > ----- > > ClassA: > ClassB B > ClassC C > > ClassB: > (other fields) > //I don't want ClassC referenced here. > > > > Any idea how I can tell NHibernate to write the foreign key for TableB- > >TableC on an insert, with the minimal amount of pollution of my > domain model. > > -- > You received this message because you are subscribed to the Google Groups > "nhusers" group. > To post to this group, send email to [email protected]. > To unsubscribe from this group, send email to > [email protected]<nhusers%[email protected]> > . > For more options, visit this group at > http://groups.google.com/group/nhusers?hl=en. > > -- Fabio Maulo -- You received this message because you are subscribed to the Google Groups "nhusers" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/nhusers?hl=en.
