Received: from localhost (unknown [200.46.204.184]) by postgresql.org (Postfix) with ESMTP id AB6F59F9FDD for ; Wed, 5 Sep 2007 10:13:26 -0300 (ADT) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.204.184]) (amavisd-maia, port 10024) with ESMTP id 94766-05 for ; Wed, 5 Sep 2007 10:13:14 -0300 (ADT) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.5 Received: from rv-out-0910.google.com (rv-out-0910.google.com [209.85.198.188]) by postgresql.org (Postfix) with ESMTP id A48339F9EC7 for ; Wed, 5 Sep 2007 10:13:21 -0300 (ADT) Received: by rv-out-0910.google.com with SMTP id l15so1332754rvb for ; Wed, 05 Sep 2007 06:13:19 -0700 (PDT) DKIM-Signature: a=rsa-sha1; c=relaxed/relaxed; d=gmail.com; s=beta; h=domainkey-signature:received:received:message-id:date:from:sender:to:subject:cc:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references:x-google-sender-auth; b=AmmSaBH++4mlFXHFqYVMwJz0dXJmUTJ8S+stlmW15ynjSHjIm+MWpGPxC71HVpu0yBcyiLENnzUwwJke2upiwnhFMeW/Ud8fIqjU1MGet494nWrLjtqsClKWJN3/jgD/R4R048vsZ4uUVwFqXJUQQYcGFcDKzy9QBjE+4KEYans= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=beta; h=received:message-id:date:from:sender:to:subject:cc:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references:x-google-sender-auth; b=ojmJPfvxPGkmR95HkBA1aXfeI6oJqCezhcja3FdiSD9vhL5/jlph9WYSQAzp1ju/Di3KYlcHY5hEER4uCuXVMDwgfqFLOWNW2VlULvyK+gtpDfYdWbeWiFP3DTegehk5U0w0UTm1Ao/1LEKrMQpOJJCog6hG3k/tbt5gxnkMUG8= Received: by 10.140.207.2 with SMTP id e2mr2808658rvg.1188997999634; Wed, 05 Sep 2007 06:13:19 -0700 (PDT) Received: by 10.141.69.7 with HTTP; Wed, 5 Sep 2007 06:13:19 -0700 (PDT) Message-ID: Date: Wed, 5 Sep 2007 15:13:19 +0200 From: "Peter Kovacs" To: "Heikki Linnakangas" Subject: Re: PreparedStatement rounds doubles to scale 14 during update Cc: pgsql-jdbc@postgresql.org In-Reply-To: <46DE9C1F.6030407@enterprisedb.com> MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Content-Disposition: inline References: <46DE7E7A.70208@enterprisedb.com> <46DE9C1F.6030407@enterprisedb.com> X-Google-Sender-Auth: c7da3267ae84349c X-Virus-Scanned: Maia Mailguard 1.0.1 X-Archive-Number: 200709/17 X-Sequence-Number: 17439 Thank you for the python reference, it is very instructive indeed. I find it strange that the type mapping specification is in a tutorial by Sun and not in a more formal document. Thanks Peter On 9/5/07, Heikki Linnakangas wrote: > Peter Kovacs wrote: > > Heikki, > > > > Thank you for your reply. > > > > What are base-10 datatypes? Are they numeric types? I cannot find them > > in the backend documentation. > > I meant any data type that can accurately represent a base-10 decimal > number. In PostgreSQL, that's numeric. In Java, it's BigDecimal. > > If you're not familiar with the differences between floating point and > decimal numbers, I'd suggest you to read on it. This python tutorial for > example has a pretty good chapter on the issues: > http://docs.python.org/tut/node16.html > > > Is there a mapping of Java types to backend types documented somewhere? > > There is for mapping between Java types and SQL types, see "Getting > Started with with the JDBC API" by Sun: > > http://java.sun.com/j2se/1.5.0/docs/guide/jdbc/getstart/mapping.html > > -- > Heikki Linnakangas > EnterpriseDB http://www.enterprisedb.com >