I have two tables with compound keys and a table of links between them:
AND
AT
Communication
- help
- rate
- sharedkey
- Sortortr
So the inconvenient thing is the shared key, which is part of both FKs. Here's the first thing I tried (I use Fluent, but I would have the same problem with XML mappings):
mapping.HasManyToMany(x => x.Bees)
.Table("Linking")
.ParentKeyColumns.Add("aid", "sharedkey")
.ChildKeyColumns.Add("bid", "sharedkey")
.OrderBy("sortorder");
Which gives me a matching exception: "Duplicate column when matching for collection" because I inserted twice sharedkey. This makes sense because I did not say at NH that I really want to sharedkeybe the same in every direction.
Java- Hibernate formula , , NH, AFAIK, . , ?
:
user24359