Re: float formating with xx.00

From: Richard Huxton <dev(at)archonet(dot)com>
To: map(at)inter-resa(dot)com, pgsql-general(at)postgresql(dot)org
Subject: Re: float formating with xx.00
Date: 2003-07-06 07:33:03
Message-ID: 200307060833.04095.dev@archonet.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On Thursday 03 Jul 2003 8:42 pm, Mark wrote:
> Hy,
>
> I am trying to enter 19.00 in a float field... no error but the data
> (select) is showing 19 without the "trailing" zeros... But for format and
> standard presentation of money, I need to keep any last zero digit.
>
> How can I do this? I run version 7.1x
> Thanks!

Consider using the numeric type, or you can cast to it for output.

select 19::numeric(9,2);
numeric
---------
19.00

--
Richard Huxton

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Peter Hopfgartner 2003-07-06 09:25:50 Dbweaver: A small tool to help database programmers
Previous Message Maksim Likharev 2003-07-06 06:58:40 Re: PostGreSql equivalents to mssql