X-Original-To: pgsql-jdbc-postgresql.org@localhost.postgresql.org Received: from localhost (av.hub.org [200.46.204.144]) by postgresql.org (Postfix) with ESMTP id D95E49DC9C3 for ; Fri, 17 Feb 2006 12:12:06 -0400 (AST) Received: from postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 63921-06 for ; Fri, 17 Feb 2006 12:12:04 -0400 (AST) X-Greylist: from auto-whitelisted by SQLgrey- Received: from smtp.uk.colt.net (smtp.uk.colt.net [195.110.64.125]) by postgresql.org (Postfix) with ESMTP id 0F9FC9DC9A0 for ; Fri, 17 Feb 2006 12:12:02 -0400 (AST) Received: from [10.0.1.82] (117-21-161-212.DSL.ONCOLT.COM [212.161.21.117]) by smtp.uk.colt.net (Postfix) with ESMTP id 5F6D0145BEF for ; Fri, 17 Feb 2006 16:09:20 +0000 (GMT) From: David Goodenough To: pgsql-jdbc@postgresql.org Subject: setString and timestamps Date: Fri, 17 Feb 2006 16:07:17 +0000 User-Agent: KMail/1.9.1 MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Content-Disposition: inline Message-Id: <200602171607.18071.david.goodenough@btconnect.com> X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, score=1.559 required=5 tests=[AWL=-0.360, DNS_FROM_RFC_ABUSE=0.479, DNS_FROM_RFC_POST=1.44] X-Spam-Score: 1.559 X-Spam-Level: * X-Archive-Number: 200602/127 X-Sequence-Number: 14724 I understand from looking at the archive that there some changes around 8.0 in this area, but I am confused as to how to proceed. I have some code which takes a table and inserts values into it where the values have come from XML and are thus all strings. Some of these XML fields are timestamps, but this generic code does not have table specific=20 knowledge. =46rom what I have read I think I have to use something like the metadata for this table to find the type of this column, and if it is a timestamp th= en I need to take the string and convert it into a timestamp before I set it into the parameterized insert. Is this right, and are there any other=20 datatypes which are not implicitly converted from String to whatever is necessary? If it is only timestamps, why are they singled out for this special treatme= nt? Also there was some question about the difference between timestamps with and without zone, mine are without should that make a difference. Is there a HOWTO about this somewhere? David