[hibernate-issues] [Hibernate-JIRA] Created: (HHH-6754) Derived Identifiers and Inheritance not working together

Jason Pyeron (JIRA) noreply at atlassian.com
Fri Oct 21 11:22:22 EDT 2011


Derived Identifiers and Inheritance not working together
--------------------------------------------------------

                 Key: HHH-6754
                 URL: http://opensource.atlassian.com/projects/hibernate/browse/HHH-6754
             Project: Hibernate Core
          Issue Type: Bug
          Components: core
    Affects Versions: 3.6.7
            Reporter: Jason Pyeron


// striped down for clarity

@Entity
public class Base //Works
{
    @Id @ManyToOne ParentA id1;
    @Id @ManyToOne Value id2;
}

@Entity
@Inheritance(strategy=InheritanceType.JOINED)
@DiscriminatorColumn(name="dtype",discriminatorType=DiscriminatorType.STRING)
public class Base2 //Works
{
    @Id @ManyToOne ParentA id1;
    @Id @ManyToOne Value id2;
}


@Entity
@Inheritance(strategy=InheritanceType.JOINED)
@DiscriminatorColumn(name="dtype",discriminatorType=DiscriminatorType.STRING)
public class Base3 //Fails
{
    @Id @ManyToOne ParentA id1;
    @Id @ManyToOne Value id2;
}

@Entity
@DiscriminatorValue("subtype")
public class Subtype extends Base3
{
}


--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

        


More information about the hibernate-issues mailing list