AW: ALTER TABLE DROP COLUMN - Mailing list pgsql-hackers

From Zeugswetter Andreas SB
Subject AW: ALTER TABLE DROP COLUMN
Date
Msg-id 11C1E6749A55D411A9670001FA68796336809F@sdexcsrv1.f000.d0188.sd.spardat.at
Whole thread Raw
Responses Re: AW: ALTER TABLE DROP COLUMN  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-hackers
> WAL would provide the framework to do something like that, but I still
> say it'd be a bad idea.  What you're describing is
> irrevocable-once-it-starts DROP COLUMN; there is no way to 
> roll it back.
> We're trying to get rid of statements that act that way, not add more.

Yes.

> I am not convinced that a 2x penalty for DROP COLUMN is such a huge
> problem that we should give up all the normal safety features of SQL
> in order to avoid it.  Seems to me that DROP COLUMN is only a 
> big issue during DB development, when you're usually working with 
> relatively small amounts of test data anyway.

Here I don't agree, the statement can also be used for an application version
upgrade.  Thus seen in SAP/R3 with tables > 30 Gb.

My conclusion would be that we need both:
1. a fast system table only solution with physical/logical column id
2. a tool that does the cleanup (e.g. vacuum) 

Andreas 


pgsql-hackers by date:

Previous
From: Zeugswetter Andreas SB
Date:
Subject: AW: Proposal: TRUNCATE TABLE table RESTRICT
Next
From: Philip Warner
Date:
Subject: Re: AW: backup and restore