Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.80) (envelope-from ) id 1VJWYc-0004ZC-AB for pgsql-jdbc@arkaria.postgresql.org; Tue, 10 Sep 2013 22:37:14 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.80) (envelope-from ) id 1VJWYb-0003gi-FM for pgsql-jdbc@arkaria.postgresql.org; Tue, 10 Sep 2013 22:37:13 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtp (Exim 4.80) (envelope-from ) id 1VJWYa-0003gc-TX for pgsql-jdbc@postgresql.org; Tue, 10 Sep 2013 22:37:12 +0000 Received: from mail63.csoft.net ([205.205.214.4]) by magus.postgresql.org with esmtp (Exim 4.80) (envelope-from ) id 1VJWYX-00087C-0Y for pgsql-jdbc@postgresql.org; Tue, 10 Sep 2013 22:37:12 +0000 Received: from leary.csoft.net (leary.csoft.net [205.205.214.5]) by mail63.csoft.net (Postfix) with ESMTP id 01F9128414; Tue, 10 Sep 2013 17:37:05 -0500 (EST) Received: by leary.csoft.net (Postfix, from userid 1112) id CAF1EA158; Tue, 10 Sep 2013 18:37:04 -0400 (EDT) Date: Tue, 10 Sep 2013 18:37:04 -0400 (EDT) From: Kris Jurka X-X-Sender: books@leary.csoft.net To: Lachezar Dobrev cc: List Subject: Re: Regression: Problems with Timestamp arguments In-Reply-To: Message-ID: References: User-Agent: Alpine 2.03 (BSO 1266 2009-07-14) MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII X-Pg-Spam-Score: -2.6 (--) List-Archive: List-Help: List-ID: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: X-Mailing-List: pgsql-jdbc Precedence: bulk Sender: pgsql-jdbc-owner@postgresql.org On Tue, 10 Sep 2013, Lachezar Dobrev wrote: > I've made a blunt stab at working around the issue. > The attached patch adds a new parameter to the JDBC URL: timestamp. > The parameter can be wither 'with_timezone' or 'without_timezone'. If > the parameter is missing, or has a different value then the current > behaviour (using Oid.UNSPECIFIED) is exhibited. With the parameters > specified correctly one of the Oid.TIMESTAMP or Oid.TIMESTAMPTZ is > used when sending Timestamp arguments to the server. This won't really work in general though. If you have a database that has both timestamp and timestamptz fields in it, there is no valid setting of this configuration option. Setting it either way will result in silent corruption of your data. Kris Jurka -- Sent via pgsql-jdbc mailing list (pgsql-jdbc@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-jdbc