Re: Clean up wasNullFlag usage

Поиск
Список
Период
Сортировка
От Kris Jurka
Тема Re: Clean up wasNullFlag usage
Дата
Msg-id Pine.BSO.4.64.0707270455120.2617@leary.csoft.net
обсуждение исходный текст
Ответ на Clean up wasNullFlag usage  (Mikko Tiihonen <mikko.tiihonen@iki.fi>)
Список pgsql-jdbc

On Sat, 21 Jul 2007, Mikko Tiihonen wrote:

> The wasNullFlag must be evaluated for each getXXX method invocation.
> Currently it is done all over the ResultSet classes. The patch moves
> the evaluation inside checkResultSet method that is already invoked at
> the beginning of each getXXX method. Also updates the javadoc to be
> explicit about the functionality.
>

One of the reasons for doing the ad-hoc null flag setting was to avoid
multiple checkResultSet calls like you've now introduced for things like
getByte.  Rethinking that decision now, the performance impact of
checkResultSet is virtually non-existent, so this cleanup makes sense.

Applied with some additional minor modifications (missed
Jdbc[24]ResultSet, mention the fact that getFastXXX can no longer handle
null values).

I don't like slipping in unrelated functionality changes like this one,
which I took out:

+        if (fields[columnIndex - 1].getOID() == Oid.BOOL) {
+            return toBoolean(getFixedString(columnIndex)) ? 1 : 0;
+        }

I'm not opposed to the idea, but please raise things like this as separate
issues and not silently lump it in with a change that supposedly didn't
affect functionality.  Please resubmit.

Kris Jurka


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

Предыдущее
От: "Hui Ye"
Дата:
Сообщение: Issue with batch update and timestamp escape syntax error
Следующее
От: Kris Jurka
Дата:
Сообщение: Re: Issue with batch update and timestamp escape syntax error