Skip site navigation (1) Skip section navigation (2)

Re: [PATCHES] ALTER TABLE ... SET TABLESPACE

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Gavin Sherry <swm(at)linuxworld(dot)com(dot)au>
Cc: Tatsuo Ishii <t-ishii(at)sra(dot)co(dot)jp>, pgsql-hackers(at)postgresql(dot)org
Subject: Re: [PATCHES] ALTER TABLE ... SET TABLESPACE
Date: 2004-06-21 01:14:07
Message-ID: 11570.1087780447@sss.pgh.pa.us (view raw or flat)
Thread:
Lists: pgsql-hackerspgsql-patches
Gavin Sherry <swm(at)linuxworld(dot)com(dot)au> writes:
> On Mon, 21 Jun 2004, Tatsuo Ishii wrote:
>> Also I think we need to enhance ALTER INDEX to assign new table spaces
>> for indexes. Assigning different tables spaces for tables and indexes
>> are essential to gain more I/O speed IMO.

> I thought about this. ALTER INDEX doesn't exist yet and I figured that,
> unlike the case of tables, its easy to drop and recreate indexes in new
> tablespaces.

The precedents we already have (ALTER OWNER, RENAME, SET STATISTICS)
are that ALTER TABLE applies to any relation type for which it makes
sense.  So I'd expect ALTER TABLE SET TABLESPACE to just work on
indexes, not that we'd go and invent an ALTER INDEX ... command.

Given that you implement the data transfer as a straight block-by-block
copy and not some kind of tuple-at-a-time thing, I would think that
it would be trivial to consider them the same case from an
implementation point of view, too.

			regards, tom lane

In response to

Responses

pgsql-hackers by date

Next:From: Tom LaneDate: 2004-06-21 01:17:40
Subject: Re: nested xacts and phantom Xids
Previous:From: Tom LaneDate: 2004-06-21 00:49:22
Subject: Re: nested xacts and phantom Xids

pgsql-patches by date

Next:From: Tom LaneDate: 2004-06-21 01:17:40
Subject: Re: nested xacts and phantom Xids
Previous:From: Tom LaneDate: 2004-06-21 00:49:22
Subject: Re: nested xacts and phantom Xids

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group