Re: patch : Allow toast tables to be moved to a different tablespace
Robert Haas <robertmhaas@gmail.com>
From: Robert Haas <robertmhaas@gmail.com>
To: Jaime Casanova <jaime@2ndquadrant.com>
Cc: Julien Tachoires <julmon@gmail.com>, pgsql-hackers@postgresql.org
Date: 2011-12-12T16:48:07Z
Lists: pgsql-hackers
On Sat, Dec 10, 2011 at 4:16 PM, Jaime Casanova <jaime@2ndquadrant.com> wrote: >>> now, if we are now supporting this variants >>> ALTER TABLE SET TABLE TABLESPACE >>> ALTER TABLE SET TOAST TABLESPACE >>> >>> why not also support ALTER TABLE SET INDEX TABLESPACE which should >>> have the same behaviour as ALTER INDEX SET TABLESPACE... just an idea, >>> and of course not necessary for this patch > > any opinion about this? maybe i can make a patch for that if there is > consensus that it could be good for symettry I'm not really convinced we need it. I think it would end up just being a shorthand for ALTER INDEX .. SET TABLESPACE for each index. Most tables don't have more than a handful of indexes, so it doesn't seem like we'd be gaining much (compare GRANT ... ON ALL TABLES IN SCHEMA, which could easily be a shorthand for hundreds or perhaps even thousands of individual GRANT statements). Also, it seems that we haven't really discussed much why moving the TOAST table to a different tablespace from the main table might be useful. I'm not saying we shouldn't have it if it's good for something, but what's the reason for wanting it? -- Robert Haas EnterpriseDB: http://www.enterprisedb.com The Enterprise PostgreSQL Company