Open lukasj opened 6 years ago
MapJoin.key() return a Path which can not be a join source. For example,
MapJoin.key()
@Entity public class Store { @ElementCollection(fetch=FetchType.LAZY) Map<Merchandise, Integer> inventory; } @Entity public class Merchandise { @ManyToOne Supplier supplier; } CriteriaQuery criteriaQuery = criteriaBuilder.createCriteriaQuery(Store.class); Root root = criteriaQuery.from(Store.class); root.joinMap("inventory").key().join("supplier");
The key() return a Path that can not join any association or element collection. Join source must be a From.
key()
Path
From
MapJoin.key()
return a Path which can not be a join source. For example,The
key()
return aPath
that can not join any association or element collection. Join source must be aFrom
.