pg.ddx.io  pgsql-jdbc@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Matt Magoffin <postgresql.org@msqr.us>
To: Kris Jurka <books@ejurka.com>
Cc: pgsql-jdbc@postgresql.org
Subject: Re: how to set a PreparedStatement column of XML type in    8.3?
Date: Mon, 17 Dec 2007 17:16:26 +1300 (NZDT)
Message-ID: <50955.192.168.1.108.1197864986.squirrel@msqr.us> (raw)
In-Reply-To: <Pine.BSO.4.64.0712151114550.2580@leary.csoft.net>
References: <51046.192.168.1.108.1197434523.squirrel@msqr.us>
	<50753.192.168.1.108.1197501684.squirrel@msqr.us>
	<Pine.BSO.4.64.0712121855050.17882@leary.csoft.net>
	<50997.192.168.1.108.1197506381.squirrel@msqr.us>
	<Pine.BSO.4.64.0712130051180.2048@leary.csoft.net>
	<59655.192.168.1.108.1197614334.squirrel@msqr.us>
	<Pine.BSO.4.64.0712140524590.15803@leary.csoft.net>
	<49230.192.168.1.108.1197663372.squirrel@msqr.us>
	<Pine.BSO.4.64.0712151114550.2580@leary.csoft.net>

>> What about with calls to setObject(int, Object, int) when a String is
>> passed in and the type set to Types.OTHER? Would it be possible then...
>> say if Object is a String, to treat it as if the stringtype=unspecified
>> parameter was set?
>
> I've implemented this for the 8.3 driver in CVS.  It takes
> Object.toString() of anything given with Types.OTHER, so it doesn't
> necessarily need to be in String form already.
>
> I've uploaded some jars here if you want to give it a test.
>
> http://ejurka.com/pgsql/jars/mm/

Yep, that did the trick for me. Thanks!

-- m@



view thread (14+ messages)

Message-ID: <50955.192.168.1.108.1197864986.squirrel@msqr.us>
Permalink:  ../50955.192.168.1.108.1197864986.squirrel@msqr.us/
Also on:    postgresql.org/message-id/50955.192.168.1.108.1197864986.squirrel@msqr.us

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-jdbc@postgresql.org
  Cc: postgresql.org@msqr.us, books@ejurka.com
  Subject: Re: how to set a PreparedStatement column of XML type in    8.3?
  In-Reply-To: <50955.192.168.1.108.1197864986.squirrel@msqr.us>
  References: <51046.192.168.1.108.1197434523.squirrel@msqr.us> <50753.192.168.1.108.1197501684.squirrel@msqr.us> <Pine.BSO.4.64.0712121855050.17882@leary.csoft.net> <50997.192.168.1.108.1197506381.squirrel@msqr.us> <Pine.BSO.4.64.0712130051180.2048@leary.csoft.net> <59655.192.168.1.108.1197614334.squirrel@msqr.us> <Pine.BSO.4.64.0712140524590.15803@leary.csoft.net> <49230.192.168.1.108.1197663372.squirrel@msqr.us> <Pine.BSO.4.64.0712151114550.2580@leary.csoft.net> <50955.192.168.1.108.1197864986.squirrel@msqr.us>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox