Re: Bug: Cannot pass null in Parameter in Query for ISNULL

Поиск
Список
Период
Сортировка
От Mikko Tiihonen
Тема Re: Bug: Cannot pass null in Parameter in Query for ISNULL
Дата
Msg-id 4ED74716.7070904@nitorcreations.com
обсуждение исходный текст
Ответ на Re: Bug: Cannot pass null in Parameter in Query for ISNULL  (bht@actrix.gen.nz)
Ответы Re: Bug: Cannot pass null in Parameter in Query for ISNULL  (Oliver Jowett <oliver@opencloud.com>)
Список pgsql-jdbc
On 12/01/2011 09:58 AM, bht@actrix.gen.nz wrote:
> Hi Oliver,
>
> Thanks for your reply. Onfortunately I cannot see a solution in your
> elaboration. However I am still confident that there will be one at
> some point in the future.
>
>  From an application perspective it is of course nonsense to code
> variations of the same SQL statement depending on parameters having
> specific values as required by the workaround. In case of JPA this
> option does not even exist.
>
> A Java application programmer has to go through extreme hassle in such
> a simple case. That hassle is not worth it.

So far it has been established that the JPA implementation you are
using uses an unportable hack that happens to work for some DB vendors
but not with postgresql.

Can you comment on why our proposal to remove the hack from the JPA
implementation and replace it with the JDBC recommended way of sending
NULL is not the correct way forward?

This would enable the JPA driver to work with any DB vendor providing
a standard compliant JDBC driver such as postgres, mysql, oracle etc.

As the promise of a JPA layer is to abstract the DB specifics away,
when you report the issue to your JPA vendor it should be of high
priority to them to fix their code. In this particular case the
JPA implementation has the correct type information readily at hand
but the forgets to pass it to the JDBC driver as recommeneded in
JDBC specification.

PS. Have you tried if a newer version of the JPA implementation you are
using has already fixed the problem?

-Mikko

В списке pgsql-jdbc по дате отправления:

Предыдущее
От: bht@actrix.gen.nz
Дата:
Сообщение: Re: Bug: Cannot pass null in Parameter in Query for ISNULL
Следующее
От: Oliver Jowett
Дата:
Сообщение: Re: Bug: Cannot pass null in Parameter in Query for ISNULL