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

From: Philip Warner <pjw(at)rhyme(dot)com(dot)au>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: "Marc G(dot) Fournier" <scrappy(at)postgresql(dot)org>, Christopher Kings-Lynne <chriskl(at)familyhealth(dot)com(dot)au>, Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>, Gavin Sherry <swm(at)linuxworld(dot)com(dot)au>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: [PATCHES] ALTER SCHEMA ... SET TABLESPACE
Date: 2004-08-23 06:06:14
Message-ID: 6.1.1.1.0.20040823160022.051becb0@203.8.195.10
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers pgsql-patches

At 03:15 PM 23/08/2004, Tom Lane wrote:

>I thought the idea was for pg_dump to emit something like
>
> SET magic_tablespace_variable = some_ts;
> CREATE TABLE foo (columns...);
>
>rather than
>
> CREATE TABLE foo (columns...) TABLESPACE some_ts;
>
>the point being...

Yep.

>I am quite unsure why you are pushing this while also insisting that
>we need "die_on_errors" mode for pg_restore.

Because I expect scripts to die when they produce errors, and find the
recent change to be a step backward.

> If you are going to die
>on the first error then these alternatives are equally brittle.

Because I am told that many people like to continue regardless of errors,
in which case allowing tables to be created is way more useful & helpful.
The same is true for database & schema creation.

On the question of schemas, how would you expect:

SET magic_tablespace_variable = some_ts;
CREATE SCHEMA foo;

to behave? Would foo have a default tablespace of some_ts?

----------------------------------------------------------------
Philip Warner | __---_____
Albatross Consulting Pty. Ltd. |----/ - \
(A.B.N. 75 008 659 498) | /(@) ______---_
Tel: (+61) 0500 83 82 81 | _________ \
Fax: (+61) 03 5330 3172 | ___________ |
Http://www.rhyme.com.au | / \|
| --________--
PGP key available upon request, | /
and from pgp.mit.edu:11371 |/

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Tom Lane 2004-08-23 06:14:46 Re: [PATCHES] ALTER SCHEMA ... SET TABLESPACE
Previous Message Tom Lane 2004-08-23 05:15:09 Re: [PATCHES] ALTER SCHEMA ... SET TABLESPACE

Browse pgsql-patches by date

  From Date Subject
Next Message Tom Lane 2004-08-23 06:14:46 Re: [PATCHES] ALTER SCHEMA ... SET TABLESPACE
Previous Message Tom Lane 2004-08-23 05:15:09 Re: [PATCHES] ALTER SCHEMA ... SET TABLESPACE