Hi All.
I am running hibernate 1.2 with postgresql 7.2.4.
I would like to do a HQL query like the following WHERE clause.
Code:
SELECT table
FROM table IN class com.sys.hib.Table, item IN class com.sys.hib.Item
WHERE table.tableId = item.tableId
AND NOT (table.statusId IN ('bad','worse') AND table.startTime > item.eolTime)
AND table.tableId =:passedTableId
The problem is the query in psql works fine but in hibernate the nested part of the query is always met even if it shouldn't be.
I also tried the following with the same result:
Code:
AND (table.statusId NOT IN ('bad','worse') OR table.startTime < item.eolTime)
I am not sure if this is fixed in a newer version of hibernate.
If so it could be the reason I need to get around to upgrading.
Thanks in advance.
Ian...