X-Original-To: pgsql-jdbc-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.144]) by svr1.postgresql.org (Postfix) with ESMTP id C8584D1B173 for ; Tue, 6 Jul 2004 18:01:45 -0300 (ADT) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 73598-03 for ; Tue, 6 Jul 2004 21:01:46 +0000 (GMT) Received: from mail63.csoft.net (leary3.csoft.net [63.111.22.74]) by svr1.postgresql.org (Postfix) with SMTP id 73BE6D1B1AB for ; Tue, 6 Jul 2004 18:01:25 -0300 (ADT) Received: (qmail 4971 invoked by uid 1112); 6 Jul 2004 21:01:15 -0000 Date: Tue, 6 Jul 2004 16:01:15 -0500 (EST) From: Kris Jurka X-X-Sender: books@leary.csoft.net To: Dave Cramer Cc: "pgsql-jdbc@postgresql.org" Subject: Re: getXXX methods In-Reply-To: <1089145387.1506.65.camel@localhost.localdomain> Message-ID: References: <1088795907.1536.118.camel@localhost.localdomain> <1089145387.1506.65.camel@localhost.localdomain> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, hits=0.0 tagged_above=0.0 required=5.0 tests= X-Spam-Level: X-Archive-Number: 200407/41 X-Sequence-Number: 10425 On Tue, 6 Jul 2004, Dave Cramer wrote: > Once possibility is to use Double.parseDouble(s).byteValue() > > so the code would become > > try > { > Byte.parseByte(s) > } Why bother with Byte.parseByte at all if you are going to fall back to the double parsing anyway? As I mentioned earlier I think it is better to throw an Exception rather than to silently alter the returned data. Kris Jurka