Received: from localhost (unknown [200.46.204.183]) by mail.postgresql.org (Postfix) with ESMTP id 317CC6329EB for ; Fri, 24 Apr 2009 06:05:18 -0300 (ADT) Received: from mail.postgresql.org ([200.46.204.86]) by localhost (mx1.hub.org [200.46.204.183]) (amavisd-maia, port 10024) with ESMTP id 45484-03 for ; Fri, 24 Apr 2009 06:05:15 -0300 (ADT) X-Greylist: from auto-whitelisted by SQLgrey-1.7.6 Received: from mk-filter-2-a-1.mail.uk.tiscali.com (mk-filter-2-a-1.mail.uk.tiscali.com [212.74.100.53]) by mail.postgresql.org (Postfix) with ESMTP id C09216329A0 for ; Fri, 24 Apr 2009 06:05:15 -0300 (ADT) X-Trace: 186994513/mk-filter-2.mail.uk.tiscali.com/B2C/$b2c-THROTTLED-DYNAMIC/b2c-CUSTOMER-DYNAMIC-IP/80.225.82.61/None/john.lister-ps@kickstone.com X-SBRS: None X-RemoteIP: 80.225.82.61 X-IP-MAIL-FROM: john.lister-ps@kickstone.com X-SMTP-AUTH: X-MUA: Thunderbird 2.0.0.21 (Windows/20090302) X-IP-BHB: Once X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: AtABANcd8UlQ4VI9/2dsb2JhbAAI0FyDdAU X-IronPort-AV: E=Sophos;i="4.40,240,1238972400"; d="scan'208";a="186994513" Received: from 80-225-82-61.dynamic.dial.as9105.com (HELO [192.168.6.11]) ([80.225.82.61]) by smtp.tiscali.co.uk with ESMTP; 24 Apr 2009 10:05:12 +0100 Message-ID: <49F180D3.6070203@kickstone.com> Date: Fri, 24 Apr 2009 10:05:23 +0100 From: John Lister User-Agent: Thunderbird 2.0.0.21 (Windows/20090302) MIME-Version: 1.0 To: Peter CC: 'Kris Jurka' , pgsql-jdbc@postgresql.org Subject: Re: JDBC problem with dates and ANYELEMENT type References: <00e701c9c3eb$625d43a0$2717cae0$@com> <01e001c9c4b8$e28c93a0$a7a5bae0$@com> In-Reply-To: <01e001c9c4b8$e28c93a0$a7a5bae0$@com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=0 tagged_above=0 required=5 tests=none X-Spam-Level: X-Archive-Number: 200904/85 X-Sequence-Number: 19532 > What are the potential implications if I patch setDate() method in AbstractJdbc2Statement to pass OID.Date instead of 'unspecified'? Would that break anything else? We don’t use timestamps anywhere in the app yet, so I'm not really worried about timezone being potentially screwed up. > Reading the comments i would guess this would break a few things :( But i didn't think postgresql supported dates with timezones (times yes but not dates), so is the driver being overly cautious. Isn't passing it as unspecified with a timezone, effectively passing a timestamp instead of a date. Having the result be in the servers timezone might be unexpected if the calendar parameter has a timezone, but isn't it the correct behaviour? Similarly looking at the binary patch posted previously, there is a comment that dates aren't transmitted in binary because the unit tests fail as they expect millisecond accuracy, surely in SQL a date has no time component? If you require time as well shouldn't you be using timestamp? Just my thoughts and i guess it probably breaks a few users apps if this were applied... JOHN