strip zeros from fractional part

From: "Giovanni M(dot)" <drayah(at)gmail(dot)com>
To: pgsql-general(at)postgresql(dot)org
Subject: strip zeros from fractional part
Date: 2005-10-03 18:44:59
Message-ID: 9216699e0510031144k4430be19s3d00154b30757f9e@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Hi guys,

I am searching for a function that enables me to strip the trailing
zeros in the fractional part of a number (numeric type). For example a
number saved in a column of type numeric as such: 23.45000 would be
returned as 23.45

I can't find any function that does this in the documentation, does
something like this exist or do i need to write some custom function
myself?

Thanks for any help,

Giovanni Martina

--
A World of KEIGI
http://keigi.blogspot.com

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Dann Corbit 2005-10-03 19:01:24 Re: Integration with MS Sql Server
Previous Message J B 2005-10-03 17:55:52 Integration with MS Sql Server