Re: [HACKERS] ALTER TABLE ADD COLUMN column SERIAL -- unexpected results

2001-07-17 Thread Hiroshi Inoue
Tom Lane wrote: > > Hiroshi Inoue <[EMAIL PROTECTED]> writes: > > Christopher Kings-Lynne wrote: > >> Just out of interest, is there a special reason it's difficult to implement > >> the DEFAULT feature of alter table add column? > > > Without *DEFAULT* we don't have to touch the table file > > a

Re: [HACKERS] ALTER TABLE ADD COLUMN column SERIAL -- unexpected results

2001-07-17 Thread Tom Lane
Hiroshi Inoue <[EMAIL PROTECTED]> writes: > Christopher Kings-Lynne wrote: >> Just out of interest, is there a special reason it's difficult to implement >> the DEFAULT feature of alter table add column? > Without *DEFAULT* we don't have to touch the table file > at all. With *DEFAULT* we have to

RE: [HACKERS] ALTER TABLE ADD COLUMN column SERIAL -- unexpected results

2001-07-16 Thread Christopher Kings-Lynne
> *ALTER TABLE* isn't as easy as *CREATE TABLE*. > It has another problem because it hasn't implemented > *DEFAULT* yet. Just out of interest, is there a special reason it's difficult to implement the DEFAULT feature of alter table add column? Chris ---(end of broadcast

Re: [HACKERS] ALTER TABLE ADD COLUMN column SERIAL -- unexpected results

2001-07-16 Thread Hiroshi Inoue
Christopher Kings-Lynne wrote: > > > *ALTER TABLE* isn't as easy as *CREATE TABLE*. > > It has another problem because it hasn't implemented > > *DEFAULT* yet. > > Just out of interest, is there a special reason it's difficult to implement > the DEFAULT feature of alter table add column? > With

Re: [HACKERS] ALTER TABLE ADD COLUMN column SERIAL -- unexpected results

2001-07-16 Thread Hiroshi Inoue
Tom Lane wrote: > > "Rod Taylor" <[EMAIL PROTECTED]> writes: > > Running: > > ALTER TABLE table ADD COLUMN column SERIAL; > > Defines a column as int4 but does not create the sequence or attempt > > to set the default value. > > Yeah ... SERIAL is implemented as a hack in the parsing of CREATE

Re: [HACKERS] ALTER TABLE ADD COLUMN column SERIAL -- unexpected results

2001-07-16 Thread Bruce Momjian
> "Rod Taylor" <[EMAIL PROTECTED]> writes: > > Running: > > ALTER TABLE table ADD COLUMN column SERIAL; > > Defines a column as int4 but does not create the sequence or attempt > > to set the default value. > > Yeah ... SERIAL is implemented as a hack in the parsing of CREATE > TABLE, but there

Re: [HACKERS] ALTER TABLE ADD COLUMN column SERIAL -- unexpected results

2001-07-16 Thread Tom Lane
"Rod Taylor" <[EMAIL PROTECTED]> writes: > Running: > ALTER TABLE table ADD COLUMN column SERIAL; > Defines a column as int4 but does not create the sequence or attempt > to set the default value. Yeah ... SERIAL is implemented as a hack in the parsing of CREATE TABLE, but there's no correspond