Re: Re: [INTERFACES] Trouble with JDBC2 ResultSet.getDate()

Поиск
Список
Период
Сортировка
От Palle Girgensohn
Тема Re: Re: [INTERFACES] Trouble with JDBC2 ResultSet.getDate()
Дата
Msg-id 3AF8AF64.DC970DA@partitur.se
обсуждение исходный текст
Ответ на Re: Re: [INTERFACES] Trouble with JDBC2 ResultSet.getDate()  (Bruce Momjian <pgman@candle.pha.pa.us>)
Список pgsql-jdbc
Here's a patch that works fine for me.

Cheers,
Palle

Bruce Momjian wrote:
>
> > Well, I didn't see the patch, but my message (probably you just
> > received) points to the fact that getDate shall work on a
> > timestamp column, and some kind of patch shall be applied. I
> > something like this:
> >
> > if s.length() == 10
> >  return java.sql.Date.valueOf(s)
> > else do the old 7.0.3 SimpleDateFormatter stuff.
> >
> > *or*
> >
> > try {
> >   return  java.sql.Date.valueOf(s)
> > } catch (SQLException e) {
> >   do the old SimpleDateFormatter stuff...
> > }
> >
> > sort of... gotta go, or I'd have sent you a full patch.
>
> Would you, please?  Thanks.
>
> --
>   Bruce Momjian                        |  http://candle.pha.pa.us
>   pgman@candle.pha.pa.us               |  (610) 853-3000
>   +  If your life is a hard drive,     |  830 Blythe Avenue
>   +  Christ can be your backup.        |  Drexel Hill, Pennsylvania 19026

Вложения

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

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: [HACKERS] MULTIBYTE and SQL_ASCII (was Re: Re: A bug with pgsql 7.1/jdbc and non-ascii (8-bit) chars?)
Следующее
От: Barry Lind
Дата:
Сообщение: Re: AGAIN: still no answer ... peter, or anybody knowledgeable, please ....