Re: Prefered Types - Mailing list pgsql-hackers

From Peter Eisentraut
Subject Re: Prefered Types
Date
Msg-id 1304803492.15989.23.camel@vanquo.pezone.net
Whole thread Raw
In response to Re: Prefered Types  (Alvaro Herrera <alvherre@commandprompt.com>)
List pgsql-hackers
On fre, 2011-05-06 at 18:38 -0300, Alvaro Herrera wrote:
> I remember that one of the problems put forth against this idea was
> that stuff like int2+int2 which currently returns int2 would have to
> be changed to return int4, otherwise it risks overflow which it
> currently doesn't (not because the operator would change, but rather
> because some expressions would be lexed differently).  And so on with
> other operators.  I am not sure how severe this problem is for users
> in practice -- my uneducated guess is that mostly they will not care
> about such changes.

Modulo backward compatibility concerns, I don't think it would
necessarily be wrong if int2+int2 returned int4.  sum(int2) returns
int8, and no one seems bothered by that.



pgsql-hackers by date:

Previous
From: Andrew Dunstan
Date:
Subject: Re: Why not install pgstattuple by default?
Next
From: Peter Eisentraut
Date:
Subject: Re: Why not install pgstattuple by default?