Re: Auto selection of internal representation for integer NUMERIC - Mailing list pgsql-hackers

From Tom Lane
Subject Re: Auto selection of internal representation for integer NUMERIC
Date
Msg-id 3394.1151940916@sss.pgh.pa.us
Whole thread Raw
In response to Auto selection of internal representation for integer NUMERIC  (ITAGAKI Takahiro <itagaki.takahiro@oss.ntt.co.jp>)
List pgsql-hackers
ITAGAKI Takahiro <itagaki.takahiro@oss.ntt.co.jp> writes:
> In particular, this is useful for oracle users. Oracle recommends to use
> NUMBER(n, p) for all the case where numerics are required. So they try to
> use NUMERIC on PostgreSQL instead of NUMBER. But NUMERIC is not the best
> alternative to a short integer NUMBER.

I think the correct answer to that is user education.  Anything along
the lines you are suggesting would be convoluted and would probably
introduce unexpected behaviors (eg, overflow of intermediate results
that wouldn't have overflowed if the data was really NUMERIC).
        regards, tom lane


pgsql-hackers by date:

Previous
From: "Marc G. Fournier"
Date:
Subject: Re: CVS mirror, was Re: [PATCHES] ADD/DROPS INHERIT (actually INHERIT
Next
From: "Dragan Zubac"
Date:
Subject: Transaction and table partitioning