Composite key on hasmanytomany table

Flaker's Avatar

Flaker

09 Sep, 2010 04:53 PM via web

Hi,

This is possibly a simple issue but I have been unable to find it on the forum.

I have a simple n:m relationship between entities Post and Category. Regular hbm.xml mapping will generate a composite key in the intermediate table, so there is a composite between Post_Id and Category_Id.

I have been unable to recreate this with FN. Should I be using some kind of convention with IHasManyToMany? or something like that?

BTW I have been trying to do so avoiding any kind of string. But if there is no other solution, I guess it will be fine to include some strings there.

Thanks for you help.

  1. 2 Posted by Flaker on 09 Sep, 2010 07:01 PM

    Flaker's Avatar

    My bad, I forgot to add the AsSet :(

Reply to this discussion

Preview Comments are parsed with Markdown. Help with syntax

Attached Files

    You can attach files up to 10MB

    What is the opposite of down?