Re: Reduce NUMERIC size by 2 bytes, reduce max length to 508 digits

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>
Cc: Simon Riggs <simon(at)2ndquadrant(dot)com>, PostgreSQL-general <pgsql-general(at)postgresql(dot)org>
Subject: Re: Reduce NUMERIC size by 2 bytes, reduce max length to 508 digits
Date: 2005-12-03 00:37:49
Message-ID: 10154.1133570269@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general pgsql-hackers pgsql-patches

I wrote:
> The actual effective limit on NUMERIC is presently 10^128K, which is
> probably enough to count the femtoseconds remaining until the heat death
> of the universe, and then multiply that by the number of elementary
> particles therein ;-).

Should have done my research first. A little googling says that

* The total number of particles in the universe has been
variously estimated at numbers from 10^72 up to 10^87.

* The time to the heat death of the universe has been estimated at
10^200 years (and if there's one significant digit in that exponent
I'd be surprised...)

So the product I fancifully mentioned would weigh in somewhere around
10^300, and thus be *well* within the capability of even the proposed
restricted numeric format.

regards, tom lane

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Jim C. Nasby 2005-12-03 02:22:57 Re: 8.1, OID's and plpgsql
Previous Message Tom Lane 2005-12-02 23:58:39 Re: 8.1, OID's and plpgsql

Browse pgsql-hackers by date

  From Date Subject
Next Message Joe Conway 2005-12-03 00:40:47 Re: strange behavior (corruption?) of large production
Previous Message Philip Warner 2005-12-03 00:35:04 Re: Optimizer oddness, possibly compounded in 8.1

Browse pgsql-patches by date

  From Date Subject
Next Message Atsushi Ogawa 2005-12-03 01:42:50 Re: Allow an alias for the target table in UPDATE/DELETE
Previous Message Tom Lane 2005-12-02 23:38:01 Re: Numeric 508 datatype