Re: Re: 4 billion record limit?

Поиск
Список
Период
Сортировка
От Ross J. Reedstrom
Тема Re: Re: 4 billion record limit?
Дата
Msg-id 20000728120655.A4538@rice.edu
обсуждение исходный текст
Ответ на Re: Re: 4 billion record limit?  ("Keith G. Murphy" <keithmur@mindspring.com>)
Ответы RE: Re: 4 billion record limit?  ("Andrew Snow" <als@fl.net.au>)
Список pgsql-general
On Fri, Jul 28, 2000 at 11:48:10AM -0500, Keith G. Murphy wrote:
> Mitch Vincent wrote:
> >
> > There is something else that many aren't considering. In every application
> > I've ever written to use any database I use ID numbers of my own making,
> > always they're integer. 4 billion is the limit on any integer field, not
> > just the OID so there are limitations everyone should realize when using any
> > integer for any kind of record identification purposes..
> >
> That's an excellent point, especially considering that *sequences* use
> an integer to hold their max_value, which is by default 2,147,483,647.
> You cannot go larger than that, either.  I guess it's constrained to be
> positive.  So OIDs give you more potential unique values than sequences,
> far as I can tell.

However, in each case, you've got a per table (per field, really) limit,
not a per database. Not to mention that there are work arounds: two int
fields form a nice 64 bit compund key, without any need for a 64 bit
int custom type. Admittedly cumbersome to use, but standard SQL. The
sequence is a bit more or a problem, but since it's non standard SQL
anyway, writing your own sequence that uses a numeric counter gives you
potentially infinite serials.

Ross
--
Ross J. Reedstrom, Ph.D., <reedstrm@rice.edu>
NSBRI Research Scientist/Programmer
Computer and Information Technology Institute
Rice University, 6100 S. Main St.,  Houston, TX 77005

В списке pgsql-general по дате отправления:

Предыдущее
От: Paul Caskey
Дата:
Сообщение: Re: 4 billion record limit?
Следующее
От: Erich
Дата:
Сообщение: PG vs. Oracle for larger databases