From: | John R Pierce <pierce(at)hogranch(dot)com> |
---|---|
To: | pgsql-general(at)postgresql(dot)org |
Subject: | Re: About the MONEY type |
Date: | 2016-11-30 21:35:12 |
Message-ID: | 41b73933-922e-bb6a-e264-d2204f39a816@hogranch.com |
Views: | Whole Thread | Raw Message | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general |
On 11/30/2016 12:16 PM, John McKown wrote:
> Speaking generically, I guess maybe MONEY needs to be somewhat like a
> TIMESTAMP. At least in PostgreSQL, a TIMESTAMP can contain a
> TIMEZONE. I guess a MONEY type should contain a modifier identifying
> the issuer of the currency (E.g. U.S. Dollar vs Canadian Dollar vs.
> Yen vs. Yuan vs. "precious metal").
>
>
and then it would need to be able to convert between all those
units? great fun. it probably needs a time too, as those
conversion units vary with time. worse, they vary with where you
convert the money and which way, and how much the converter skims....
In the real world, US$ -> € -> US$ will not give you back the same amount.
note, btw, TIMESTAMP WITH TIME ZONE doesn't actually store the
timezone... rather, it converts it to an internal representation of GMT,
and then converts it back to display time at the client's current (or
specified) time zone.
--
john r pierce, recycling bits in santa cruz
From | Date | Subject | |
---|---|---|---|
Next Message | George Weaver | 2016-11-30 23:01:14 | Logging for 2 instances of PostgreSQL |
Previous Message | Merlin Moncure | 2016-11-30 20:27:09 | Re: About the MONEY type |