Re: Dumb question about serial's upper limit

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: "Jim C(dot) Nasby" <jnasby(at)pervasive(dot)com>
Cc: CSN <cool_screen_name90001(at)yahoo(dot)com>, pgsql-general(at)postgresql(dot)org
Subject: Re: Dumb question about serial's upper limit
Date: 2005-10-11 06:22:23
Message-ID: 10488.1129011743@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

"Jim C. Nasby" <jnasby(at)pervasive(dot)com> writes:
> Out of curiosity... why don't we have unsigned ints?

Quick, is 42 an int or an unsigned int?

I think it'd create a slew of new ambiguous cases in the
numeric-datatype hierarchy, for what is really pretty darn small gain.
We're already just barely getting by the problem that 42 might be
intended as an int2 or int8 constant --- and at least those three
datatypes have compatible comparison semantics, so that there aren't any
fundamental semantic problems created if you decide that a constant is
one or the other. Adding unsigned types to the mix seems to me to be
likely to cause some serious issues.

But feel free to give it a try, if you think it's worth a nontrivial
amount of work.

regards, tom lane

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Tino Wildenhain 2005-10-11 06:23:45 Re: PostgreSQL's bug tracker
Previous Message Jim C. Nasby 2005-10-11 06:12:27 Re: Dumb question about serial's upper limit