Marc Logemann wrote:
>
> created an issue for it. Thanks for your ideas to make the cache
> disablement query based....
>
Dear Marc,
can you please provide a link to this issue? I'm facing the same problem
with OpenJPA 2.0.1 und DB2 V9:
I have a query based on two Date parameters (amongst others). The first time
the query is executed, it runs fine and uses SQL type DATE:
...
WHERE ((t0.A = ? OR t0.B = ? OR t0.C= ?) AND t0.Z >= ? AND t0.Z <= ?)
[params=(int) 41140, (int) 41140, (int) 41140, (Date) 2010-08-01, (Date)
2010-12-31]
The second execution looks like this ...
...
WHERE ((t0.A= ? OR t0.B= ? OR t0.C= ?) AND t0.Z >= ? AND t0.Z <= ?)
[params=(int) 41140, (int) 41140, (int) 41140, (Timestamp) 2010-08-01
14:47:05.812, (Timestamp) 2010-12-31 14:47:05.812]
... and fails with
DB2 SQL Error: SQLCODE=-181, SQLSTATE=22007
because the DB2 column is of type DATE.
Will we run into performance issues if we disable the QuerySQLCache? Our
persistence unit uses only two named queries.
Cheers,
Tobias
--
View this message in context:
http://openjpa.208410.n2.nabble.com/same-jpa-query-generates-different-SQLs-tp6081417p6249868.html
Sent from the OpenJPA Users mailing list archive at Nabble.com.