Return-Path: Delivered-To: apmail-db-derby-dev-archive@www.apache.org Received: (qmail 69558 invoked from network); 4 Sep 2006 13:27:04 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur.apache.org with SMTP; 4 Sep 2006 13:27:04 -0000 Received: (qmail 62222 invoked by uid 500); 4 Sep 2006 13:27:03 -0000 Delivered-To: apmail-db-derby-dev-archive@db.apache.org Received: (qmail 62190 invoked by uid 500); 4 Sep 2006 13:27:03 -0000 Mailing-List: contact derby-dev-help@db.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: Delivered-To: mailing list derby-dev@db.apache.org Received: (qmail 62181 invoked by uid 99); 4 Sep 2006 13:27:03 -0000 Received: from asf.osuosl.org (HELO asf.osuosl.org) (140.211.166.49) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 04 Sep 2006 06:27:03 -0700 X-ASF-Spam-Status: No, hits=0.0 required=10.0 tests=UNPARSEABLE_RELAY X-Spam-Check-By: apache.org Received-SPF: pass (asf.osuosl.org: local policy) Received: from [192.18.1.36] (HELO gmpea-pix-1.sun.com) (192.18.1.36) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 04 Sep 2006 06:27:02 -0700 Received: from d1-emea-09.sun.com ([192.18.2.119]) by gmpea-pix-1.sun.com (8.13.6+Sun/8.12.9) with ESMTP id k84DQfOr021605 for ; Mon, 4 Sep 2006 14:26:41 +0100 (BST) Received: from conversion-daemon.d1-emea-09.sun.com by d1-emea-09.sun.com (Sun Java System Messaging Server 6.2-4.02 (built Sep 9 2005)) id <0J5200K01L436A00@d1-emea-09.sun.com> (original mail from Bernt.Johnsen@Sun.COM) for derby-dev@db.apache.org; Mon, 04 Sep 2006 14:26:41 +0100 (BST) Received: from [129.159.112.201] by d1-emea-09.sun.com (Sun Java System Messaging Server 6.2-4.02 (built Sep 9 2005)) with ESMTPSA id <0J5200E19LCGZFXK@d1-emea-09.sun.com> for derby-dev@db.apache.org; Mon, 04 Sep 2006 14:26:41 +0100 (BST) Date: Mon, 04 Sep 2006 15:26:36 +0200 From: "Bernt M. Johnsen" Subject: Re: [jira] Commented: (DERBY-889) with client getTimestamp on a TIME column will print the date 1900-01-01 instead of the current date In-reply-to: <27706864.1157297843496.JavaMail.jira@brutus> Sender: Bernt.Johnsen@Sun.COM To: derby-dev@db.apache.org Reply-to: Bernt.Johnsen@Sun.COM Message-id: <44FC298C.9010303@Sun.COM> Organization: Sun Microsystems MIME-version: 1.0 Content-type: multipart/signed; boundary=------------enigBE7FD69A3B65F6D292728EA1; protocol="application/pgp-signature"; micalg=pgp-sha1 X-Enigmail-Version: 0.94.0.0 References: <27706864.1157297843496.JavaMail.jira@brutus> User-Agent: Thunderbird 1.5.0.5 (X11/20060831) X-Virus-Checked: Checked by ClamAV on apache.org X-Spam-Rating: minotaur.apache.org 1.6.2 0/1000/N --------------enigBE7FD69A3B65F6D292728EA1 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Bryan Pendleton (JIRA) wrote: > [ http://issues.apache.org/jira/browse/DERBY-889?page=3Dcomments#ac= tion_12432344 ] > > Bryan Pendleton commented on DERBY-889: > --------------------------------------- > > Hi Dan, thanks for the feedback and pointers. > > Yes, behavior (C): the current date at the time the getTimestamp() is c= alled, is the > behavior that I was attempting to achieve with the patch. I would say C is an ok approach from a practical point of view, although = D would be the ideal solution, since then the following two cases would have equal behaviour: PreparedStatement P =3D c.prepareStatement("select timeCol from verylonge= ndcomplexoperation"); ResultSet rs =3D p.execute(); java.sql.Timestamp ts =3D rs.getTimestamp(1); and PreparedStatement P =3D c.prepareStatement("select CAST(timeCol AS TIMEST= AMP) from verylongendcomplexoperation"); ResultSet rs =3D p.execute(); java.sql.Timestamp ts =3D rs.getTimestamp(1); > > Am I understanding correctly that your idea with DERBY-1811 is to split= this issue > into a client issue (DERBY-889) and an embedded issue (DERBY-1811)? Tha= t > seems like a good plan to me. > > Regarding your critique of the EmbedResultSet change, I agree that it i= s undesirable > to lose the optimization of re-using the shared Calendar object, and I = agree that it > leaves a hole in that it doesn't actively ensure any particular value f= or the DATE portion > in the case of getTimestamp(