[hibernate-dev] "derived identifier" mapping

Hardy Ferentschik hardy at hibernate.org
Thu Mar 27 06:59:43 EDT 2014


No idea. I think Emmanuel had a better understanding of the derived identifier logic. 



On 27 Jan 2014, at 06:26, Steve Ebersole <steve at hibernate.org> wrote:

> What's the rational for supporting the following?
> 
> 
> @Entity
> class Product {
>    ...
> }
> 
> @Entity
> class Order {
>    ...
> }
> 
> @Entity
> @IdClass(...)
> class OrderLine {
>    @Id
>    private Order order;
> 
>    @Id
>    private Product product;
> }
> 
> Specifically, the declaration of the OrderLine primary key.  Why would
> these not have to be `@Id @ManyToOne`?
> _______________________________________________
> hibernate-dev mailing list
> hibernate-dev at lists.jboss.org
> https://lists.jboss.org/mailman/listinfo/hibernate-dev




More information about the hibernate-dev mailing list