Forums Register Login

Composite key class relationship → ERROR: not mapped to a single property

+Pie Number of slices to send: Send
CVariacaoTO class has a composite key (FK_T, FK_F, FK_F_VARIACAO). (FK_F, FK_F_VARIACAO) are also foreign key to FVariacaoTO table, in a ManyToOne relationship.



FVariacaoTO class has two primary keys, into a @Embeddable class FVariacaoPK.

This ERROR has ocurred: referencedColumnNames(FK_F, ID) of CVariacaoTO.fVariacaoTO not mapped to a single property

Relationship is just described in CVariacaoTO class. I don't know if a need write something about relationship in FVariacaoTO class, making @OneToMany or something like that.

What usually done this error?
How usually is done this kind of relationship?
ice is for people that are not already cool. Chill with this tiny ad:
a bit of art, as a gift, the permaculture playing cards
https://gardener-gift.com


reply
reply
This thread has been viewed 693 times.
Similar Threads
JPA ManyToOne composite foreign key reference for optional target
Hibernate I18N Repeated column with composite IDs
same primary key as foreign key in two table[Hibernate Mapping]
Edit primary key, if it's a foreign key
How to map ManyToOne relationship with Composite key?
More...

All times above are in ranch (not your local) time.
The current ranch time is
Apr 16, 2024 01:56:14.