]
Fol De Rol commented on HHH-5021:
---------------------------------
Sorry, query 3 is also invalid
HQL for one-to-one associations is not fully bi-directional
-----------------------------------------------------------
Key: HHH-5021
URL:
http://opensource.atlassian.com/projects/hibernate/browse/HHH-5021
Project: Hibernate Core
Issue Type: Bug
Components: core, query-criteria, query-hql
Affects Versions: 3.3.2
Reporter: Fol De Rol
Let's assume we have two entities A and B mapped to each other with a bi-directional
one-to-one association. Let A.b and B.a are appropriate linked attributes, and A owns the
association. Let's try the following HQL queries:
1. from A where b is null
2. from B where a is null
3. from B where a.b is null
Query 1 works correctly.
Query 2 produces a wrong SQL expression.
Query 3 works, though produces a redundant SQL query.
My opinion is that query 2 should also be valid.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: