Re: About the MONEY type

From: Tobia Conforto <tobia(dot)conforto(at)gruppo4(dot)eu>
To: pgsql-general(at)postgresql(dot)org
Subject: Re: About the MONEY type
Date: 2016-11-30 15:34:13
Message-ID: CAECzQwE5wTKwvv18A-HjkDRs4=qvm-R8PoPhtaRJb3PqSk2abg@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

>> I think MONEY is a great datatype, at least in theory.
>
> I personally find it pretty useless to be honest - especially because
> the currency symbol depends on the client.

I should have been more clear: I find the underlying idea of storing a
fixed-scale decimal number as a pre-scaled int8 column a good idea.

But MONEY is the only standard datatype that does so, and in its
current implementation it's horrible, because of all the shortcomings
we both mentioned.

That's why I was asking whether: 1. is there a way to remove the
dollar and commas from its default input/output format; and 2. is
there any other fixed-scale decimal extension type that is stored as
an int8, possibly with the scale specified as part of the column
definition (eg. FIXED(4))

-Tobia

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Jehan-Guillaume de Rorthais 2016-11-30 15:43:31 Re: PostgreSQl HA solution
Previous Message Merlin Moncure 2016-11-30 15:28:21 Re: "Fuzzy" Matches on Nicknames