[hibernate-issues] [Hibernate-JIRA] Created: (HCANN-12) Metadata-annotations on jointables are unsupported

Niklas Saers (JIRA) noreply at atlassian.com
Thu Nov 19 09:41:08 EST 2009


Metadata-annotations on jointables are unsupported
--------------------------------------------------

                 Key: HCANN-12
                 URL: http://opensource.atlassian.com/projects/hibernate/browse/HCANN-12
             Project: Hibernate Commons Annotations
          Issue Type: New Feature
         Environment: Hibernate 3.3, Spring 3, JDK 1.6, MySQL 5.0
            Reporter: Niklas Saers


A jointable in Hibernate is expected to have only two fields, two foreign keys. However, this relationship often has metadata, such as when it was created, and can have discriminators, such as an enum saying what it belongs to. As requested, I've started with a forum post "https://forum.hibernate.org/viewtopic.php?f=1&t=1001044", and to get more input I've crossposted on StackOverflow: "http://stackoverflow.com/questions/1761901/multiple-manytomany-sets-from-one-join-table". The discriminator should be the easy task, but how to think about annotations on relationships is probably the underlying task.

The only solution I can think of with Hibernate right now is to make "relationship entities", but that would leave me with a bunch of poorly defined entities, rather than correctly described relationships.

Cheers

   Nik

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://opensource.atlassian.com/projects/hibernate/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        


More information about the hibernate-issues mailing list