We're updating the issue view to help you get more done. 

Unable to use String field name for criteria query when joining an embedded object

Description

This appears to be a variant of the issue reported as HHH-5792. I updated the test case for that issue to test for the case where the criteria query uses strings rather than the metamodel. The testcase demonstrates that the criteria queries work correctly when using the metamodel but fail when using string property names.

The unit test fails with the exception:

java.lang.ClassCastException: org.hibernate.jpa.internal.metamodel.SingularAttributeImpl cannot be cast to javax.persistence.metamodel.ManagedType

Environment

None

Status

Assignee

Unassigned

Reporter

Jon Kranes

Fix versions

None

Labels

backPortable

None

Suitable for new contributors

None

Requires Release Note

None

Pull Request

None

backportDecision

None

Components

Affects versions

4.3.5

Priority

Major