Numeric 508 datatype - Mailing list pgsql-patches

From Simon Riggs
Subject Numeric 508 datatype
Date
Msg-id 1132161229.4959.12.camel@localhost.localdomain
Whole thread Raw
Responses Re: Numeric 508 datatype
Re: Numeric 508 datatype
Re: Numeric 508 datatype
List pgsql-patches
Now we're into 8.2devel mode, its time to submit the previously
discussed patch that:

- reduces Numeric storage format by 2 bytes
- limits scale to +/- 508 decimal places

This is sufficient to allow Numeric to continue to be used as the
default numeric representation for all numbers in the parser.

Passes: make check on cvstip, as well as some tests not in there.

Code comments explain the new format and consequences.

As previously agreed, reviewing this is a 2 stage process:
1. review/possibly agree OK to commit
2. check with everybody on GENERAL that the restriction to 508 is
acceptable

Figure there's no point doing (2) until we agree the proposal/code is
workable.

As Atsushi-san point out, there is also come CPU optimization to be done
on Numeric comparison, and also on other areas such as aggregation. I've
not done this yet.

Best Regards, Simon Riggs

Attachment

pgsql-patches by date:

Previous
From: Bruce Momjian
Date:
Subject: Re: drop if exists
Next
From: Philip Yarra
Date:
Subject: Re: pl/pgSQL doco patch