Details
-
Bug
-
Resolution: Done
-
Major
-
EAP_EWP 5.1.0
-
None
-
Workaround Exists
-
-
When the <literal>EXISTS</literal> statement was negated in Hibernate HQL, its was incorrectly translated to SQL as <code>not (exists</code>. This issue has been resolved and the statement is now correctly translated.
-
Documented as Resolved Issue
-
NEW
Description
When using the following HQL Query in code:
FROM L0parameter l0parameter_ WHERE
NOT ((l0parameter_.zvst = '00')
AND EXISTS (SELECT 1 FROM L0parameter b))
Results in the following SQL Query:
select
l0paramete0_.ZNR as ZNR91_, l0paramete0_.ZVST as ZVST91_
from
L0PARAMETER l0paramete0_
where
l0paramete0_.ZVST<>'00'
or exists (
select 1 from L0PARAMETER l0paramete1_
)
Note that the EXISTS clause is not correct because in our HQL Query I'm adding NOT in EXISTS clause too. However, the translation didn't recognize this negation.