Details
-
Bug
-
Resolution: Done
-
Major
-
JBossAS-3.2.6 Final
-
None
Description
SourceForge Submitter: mtkopone .
OS: Linux with JDK 1.4.1
I've encountered a problem with the "IS (NOT) NULL"
expression in ejbql and jbossql when attempting to find
entities using dynamic queries.
Example EJBQL query:
SELECT OBJECT(a)
FROM A a
WHERE
a.b.c IS [NOT] NULL
Problem:
If b is a CMR field and c is a CMP field, the generated
SQL does not include the table name of the b-entity in
the SQL FROM clause, even though it's alias is used in
the SQL WHERE clause. This results in an
SQLException.
I've included a tiny patch the worked fine for me, but
since I have no experience with jjt someone should
probably check that it doesn't break anything major.
mikko koponen
Krocus Communications, Finland