Re: float output precision questions

From: Stephan Szabo <sszabo(at)megazone23(dot)bigpanda(dot)com>
To: Pedro Miguel Frazao Fernandes Ferreira <pfrazao(at)ualg(dot)pt>
Cc: Peter Eisentraut <peter_e(at)gmx(dot)net>, <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: float output precision questions
Date: 2002-10-30 00:22:31
Message-ID: 20021029161452.K16452-100000@megazone23.bigpanda.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Tue, 29 Oct 2002, Peter Eisentraut wrote:

> Pedro Miguel Frazao Fernandes Ferreira writes:
>
> > Is there a way to set query output precision to maximum precision ?
> > For the type of application I mentioned this is crucial. People want to
> > get the 'same' numbers, from querys or dumps, as they inserted them.

How do you define maximum precision and "same"? With simple test programs
in C, using two digits more than DBL_DIG for printf specifier, it's easy
for me to find numbers that "change" decimal string representation in the
decimal representation -> double -> decimal representation conversion(*).
The final double you get from the second conversion should be the same as
the first, but is that what you need or do you need a stronger guarantee
than that?

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Paul Ramsey 2002-10-30 00:56:31 Re: Trigger on 'create table' ?
Previous Message Greg Patnude 2002-10-29 23:56:46 Database replication... - Mission Critical DBMS's -- Taking postgreSQL to the Enterprise Computing level...