Re: Tablespace permissions issue

From: Gavin Sherry <swm(at)linuxworld(dot)com(dot)au>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: pgsql-hackers(at)postgresql(dot)org
Subject: Re: Tablespace permissions issue
Date: 2004-06-28 17:04:12
Message-ID: Pine.LNX.4.58.0406290303080.24086@linuxworld.com.au
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Mon, 28 Jun 2004, Tom Lane wrote:

> I don't see any reasonable way for CREATE DATABASE to avoid this
> problem, since it can't necessarily look inside the source database.
> My thought is that the cleanest fix is to never allow reltablespace
> (or nsptablespace) to explicitly specify the database's default
> tablespace; that is, if you write
> CREATE TABLE ... TABLESPACE x
> and "x" is the database-level default, we should silently store zero
> instead of x's OID into reltablespace. The table would get created
> in the same place either way, but the implications for future cloning
> or dump/reload of the database would be different. The table would go
> to the new database default tablespace, whatever that is, instead of
> staying in "x".
>
> Thoughts?

I don't see any other way around it than this (other than looking at the
template database's data, but that wont happen for 7.5).

Thanks,

Gavin

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Darko Prenosil 2004-06-28 17:54:21 improper call to spi_printtup ???
Previous Message Tom Lane 2004-06-28 15:51:50 Re: Tablespace permissions issue