Re: float output precision questions
| От | Peter Eisentraut |
|---|---|
| Тема | Re: float output precision questions |
| Дата | |
| Msg-id | Pine.LNX.4.44.0210291826420.2006-100000@localhost.localdomain обсуждение исходный текст |
| Ответ на | float output precision questions (Pedro Miguel Frazao Fernandes Ferreira <pfrazao@ualg.pt>) |
| Ответы |
Re: float output precision questions
Re: float output precision questions |
| Список | pgsql-hackers |
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.
There isn't a way right now, but it's planned to be able to dump
floating-point numbers in some binary form (like printf("%A")) to be able
to restore them exactly. Not sure how that would satisfy the needs of
client interfaces, though.
> Matlab has a toolbox fucntion, claiming maximum precision, to convert
> from its double type (PostgreSQL float8) to string which does a
> sprintf('%25.18g',number).
Do we have some mathematical guarantee that this is sufficient and
necessary? If so, then it might do.
--
Peter Eisentraut peter_e@gmx.net
В списке pgsql-hackers по дате отправления: