"query specified join fetching, but the owner of the fetched association was not present in the select list" with @ElementCollection

Description

the following QueryException occours if we execute the JPQL: SELECT b FROM A a INNER JOIN a.bs b INNER JOIN FETCH b.someOtherLongs. Without the INNER JOIN FETCH b.someOtherLongs it works fine. The attribute someOtherLongs is a @ElementCollection

TestCases are attached

Environment

hibernate-entitymanager 4.2.2

Activity

Show:
Christian Beikov
September 29, 2016, 10:27 AM

I don't know if this should be transitioned to be a Hibernate core issue but this still affects Hibernate 5.2.2.

Steve Ebersole
September 29, 2016, 1:49 PM

This Jira project is used for very special query parser that is only used outside of Hibernate ORM. Did you mean to report this problem as occurring when using Hibernate ORM?

Steve Ebersole
September 29, 2016, 1:53 PM

Your tests seem to use Hibernate ORM, so it would in fact seem you just picked the wrong project - moved.

Assignee

Unassigned

Reporter

Former user

Fix versions

Labels

None

backPortable

None

Suitable for new contributors

None

Requires Release Note

None

Pull Request

None

backportDecision

None

Components

Affects versions

Priority

Major
Configure