Received: from makus.postgresql.org (makus.postgresql.org [98.129.198.125]) by mail.postgresql.org (Postfix) with ESMTP id CF47996C49C for ; Sat, 18 Feb 2012 12:30:37 -0400 (AST) Received: from sss.pgh.pa.us ([66.207.139.130]) by makus.postgresql.org with esmtp (Exim 4.72) (envelope-from ) id 1RynBE-000647-QF for pgsql-bugs@postgresql.org; Sat, 18 Feb 2012 16:30:37 +0000 Received: from sss2.sss.pgh.pa.us (tgl@localhost [127.0.0.1]) by sss.pgh.pa.us (8.14.2/8.14.2) with ESMTP id q1IGUMQ5027714; Sat, 18 Feb 2012 11:30:22 -0500 (EST) To: khalil.alijani@gmail.com cc: pgsql-bugs@postgresql.org Subject: Re: BUG #6463: tables can have at most 1600 columns In-reply-to: References: Comments: In-reply-to khalil.alijani@gmail.com message dated "Sat, 18 Feb 2012 10:16:53 +0000" Date: Sat, 18 Feb 2012 11:30:22 -0500 Message-ID: <27713.1329582622@sss.pgh.pa.us> From: Tom Lane X-Pg-Spam-Score: -1.9 (-) X-Archive-Number: 201202/132 X-Sequence-Number: 32475 > I drop a column but Postgresql still shows old (deleted) columns... > My Java program does this: > drop a boolean column and then add same column (with same name and > specification), in dozens times, because updating (this) column is very slow > !!! > AND finally it says "tables can have at most 1600 columns" Sorry, this is not a bug, or at least we're not going to fix it. The fact that DROP COLUMN doesn't physically remove the column is an intentional design decision. If we didn't do it that way, dropping a column would require rewriting the entire table (and all its indexes) and so would be horribly slow. Perhaps if you discussed why you think that repeatedly dropping and re-adding a column is a useful thing to do, we could help you find another way. The bugs list is not the place for that discussion, however. regards, tom lane