Re: how to set a PreparedStatement column of XML type in 8.3?

Поиск
Список
Период
Сортировка
От Matt Magoffin
Тема Re: how to set a PreparedStatement column of XML type in 8.3?
Дата
Msg-id 59655.192.168.1.108.1197614334.squirrel@msqr.us
обсуждение исходный текст
Ответ на Re: how to set a PreparedStatement column of XML type in 8.3?  (Kris Jurka <books@ejurka.com>)
Ответы Re: how to set a PreparedStatement column of XML type in 8.3?
Список pgsql-jdbc
>> It was hardly a complaint, just a question about how one is expected to
>> handle the xml type via JDBC in the current version of the driver.
>
> That may have came out a little wrong.  I just was trying to point out
> that expected and should have different meanings depending on what you're
> asking.  As a user of the JDBC API you should expect the driver to
> correctly map the xml type to SQLXML.  As a user of the current pg jdbc
> driver code you would not expect it to return SQLXML because it hasn't
> been implemented, so it's not that you just need to tweak something to get
> it to work.  Sorry if it came out in a negative way.

Yes, that makes sense, thanks. I suppose I was "expecting" the driver for
8.3 to simply handle a Java String <-> Postgres xml type automatically,
simply because the xml type in Postgres is sort of a glorified text type
(at the moment)... and as a user of Postgres databases that store XML data
as simple text columns, was investigating what it would be like to switch
those over to the xml type in 8.3.

Do you think it's worth considering having the 8.3 driver do this
automatic conversion of String <-> xml, so that users don't have to use
PGObject or set the stringtype=unspecified connection parameter? As a
user, it definitely has benefits for ease of use, but I understand there
might be good reasons not to do this.

-- m@



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

Предыдущее
От: Ken Johanson
Дата:
Сообщение: Re: Synthesize support for Statement.getGeneratedKeys()?
Следующее
От: Ken Johanson
Дата:
Сообщение: Patch for Statement.getGeneratedKeys()