Hello,
I have a m:n mapping and do not know how to order the results.
Here is the mapping for class Category:
Code:
<class...>
...
<bag name="Products"
table="ProductCategory"
cascade="save-update"
lazy="true" order-by="Name">
<key column="CategoryID"/>
<many-to-many class="Product"
column="ProductID"/>
</bag>
</class>
Now, ordering on "Name" does not work, of course, because that's a column in the "Product" table and not on the association table "ProductCategory". How can I reach the right table from the mapping?
Thanks,
Jan