Re: Bug #551: alter table add field serial - does not create - Mailing list pgsql-bugs

From Bruce Momjian
Subject Re: Bug #551: alter table add field serial - does not create
Date
Msg-id 200201041821.g04IL9f07152@candle.pha.pa.us
Whole thread Raw
In response to Bug #551: alter table add field serial - does not create serial field  (pgsql-bugs@postgresql.org)
List pgsql-bugs
Yes, this is a known bug:

From TODO list:

        o ALTER TABLE ADD COLUMN column SERIAL doesn't create sequence


---------------------------------------------------------------------------

pgsql-bugs@postgresql.org wrote:
> wolfgang fuertbauer (w.fuertbauer@eunet.at) reports a bug with a severity of 3
> The lower the number the more severe it is.
>
> Short Description
> alter table add field serial - does not create serial field
>
> Long Description
> altering an existing table and adding a field from type serial via
>
> >>alter table test add (s serial);<<
>
> does not add a serial, but an integer field.
>
> Sample Code
> create table t (t text);
> CREATE
> \d t
>           Table "t"
>  Attribute | Type | Modifier
> -----------+------+----------
>  t         | text |
>
> alter table t add s serial;
> ALTER
>
>  \d t
>            Table "t"
>  Attribute |  Type   | Modifier
> -----------+---------+----------
>  t         | text    |
>  s         | integer |
>
>
> No file was uploaded with this report
>
>
> ---------------------------(end of broadcast)---------------------------
> TIP 3: if posting/reading through Usenet, please send an appropriate
> subscribe-nomail command to majordomo@postgresql.org so that your
> message can get through to the mailing list cleanly
>

--
  Bruce Momjian                        |  http://candle.pha.pa.us
  pgman@candle.pha.pa.us               |  (610) 853-3000
  +  If your life is a hard drive,     |  830 Blythe Avenue
  +  Christ can be your backup.        |  Drexel Hill, Pennsylvania 19026

pgsql-bugs by date:

Previous
From: Lee Kindness
Date:
Subject: ECPG bug in --help
Next
From: Bruce Momjian
Date:
Subject: Re: Bug #552: src/backend/catalog/README