Received: from localhost (maia-3.hub.org [200.46.204.184]) by postgresql.org (Postfix) with ESMTP id 6E05A9FBC2D for ; Thu, 15 Mar 2007 13:13:28 -0300 (ADT) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.204.184]) (amavisd-new, port 10024) with ESMTP id 46909-02 for ; Thu, 15 Mar 2007 13:13:20 -0300 (ADT) X-Greylist: from auto-whitelisted by SQLgrey-1.7.4 Received: from exchange.g2switchworks.com (mail.g2switchworks.com [63.87.162.25]) by postgresql.org (Postfix) with ESMTP id 5423A9FBC4C for ; Thu, 15 Mar 2007 13:13:20 -0300 (ADT) Received: from 10.10.1.37 ([10.10.1.37]) by exchange.g2switchworks.com ([10.10.1.2]) with Microsoft Exchange Server HTTP-DAV ; Thu, 15 Mar 2007 16:13:18 +0000 Received: from state.g2switchworks.com by mail.g2switchworks.com; 15 Mar 2007 11:13:18 -0500 Subject: Re: Alter Table From: Scott Marlowe To: Shavonne Marietta Wijesinghe Cc: pgsql-sql@postgresql.org In-Reply-To: <00de01c76706$d37d56e0$1102a8c0@dream> References: <00de01c76706$d37d56e0$1102a8c0@dream> Content-Type: text/plain Content-Transfer-Encoding: 7bit Message-Id: <1173975198.12681.40.camel@state.g2switchworks.com> Mime-Version: 1.0 X-Mailer: Ximian Evolution 1.4.6 (1.4.6-2) Date: Thu, 15 Mar 2007 11:13:18 -0500 X-Virus-Scanned: Maia Mailguard 1.0.1 X-Archive-Number: 200703/215 X-Sequence-Number: 27853 On Thu, 2007-03-15 at 08:35, Shavonne Marietta Wijesinghe wrote: > When i alter a table and add a new column it always adds it to the end > of the table. Is there any way to tell it to add the new column at the > 5th position or to add the new column after a surtain column. No, but the good news is you can just recreate the table once it's stabilized in form with something like: create table new_table as select field1, field4, field2, field3 from old_table;