Skip site navigation (1) Skip section navigation (2)

Re: bug in create table with serial

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Cristóvão Dalla Costa <cbraga(at)bsi(dot)com(dot)br>
Cc: pgsql-bugs(at)postgresql(dot)org
Subject: Re: bug in create table with serial
Date: 2002-10-17 03:44:14
Message-ID: 6037.1034826254@sss.pgh.pa.us (view raw or flat)
Thread:
Lists: pgsql-bugs
=?ISO-8859-1?Q?Crist=F3v=E3o_Dalla_Costa?= <cbraga(at)bsi(dot)com(dot)br> writes:
> In PostgreSQL 7.3b2, if I create a table like so:
> create table customers (id serial primary key);

> The id field will be created of type 32 bit integer, yet the upper limit
> for the sequence will be relative to a 64 bit integer.

So?

AFAICS, you will get a failure when you reach 2^31 items.  Whether the
failure is "can't fit the value into int4" or "reached sequence maximum"
doesn't seem very exciting to me ...

			regards, tom lane

In response to

Responses

pgsql-bugs by date

Next:From: Kris JurkaDate: 2002-10-17 06:14:53
Subject: Re: bug in create table with serial
Previous:From: ir. F.T.M. van Vugt bc.Date: 2002-10-16 21:04:32
Subject: Re: multiple exception definition in pg_type.h -> error compiling postgres support in Qt with gcc v3.2 (SuSE 8.1)

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group