From: | Robert Haas <robertmhaas(at)gmail(dot)com> |
---|---|
To: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
Cc: | pgsql-hackers(at)postgresql(dot)org |
Subject: | Re: creating objects in pg_catalog |
Date: | 2012-06-06 21:09:31 |
Message-ID: | CA+TgmoYCVMZGXB3Xcm0p=8szvGLtYUeEkS=0UariqFLtdLFn6g@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On Wed, Jun 6, 2012 at 4:39 PM, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> wrote:
> Robert Haas <robertmhaas(at)gmail(dot)com> writes:
>> Right now, you can't directly create a relation (table, index,
>> composite type) in the pg_catalog schema, but you can create a
>> non-relation (function, domain, etc.) in the pg_catalog schema.
>
> Surely this is true only for superusers. Superusers can do whatever
> they want anyway, no?
No.
rhaas=# create table pg_catalog.tom (a int);
ERROR: permission denied to create "pg_catalog.tom"
DETAIL: System catalog modifications are currently disallowed.
rhaas=# create table tom (a int);
CREATE TABLE
rhaas=# alter table tom set schema pg_catalog;
ALTER TABLE
rhaas=# create domain pg_catalog.lane as int;
CREATE DOMAIN
The offending error check is in heap_create(), and based on what
you're saying here it seems like we should just rip it out.
--
Robert Haas
EnterpriseDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company
From | Date | Subject | |
---|---|---|---|
Next Message | Tom Lane | 2012-06-06 21:21:35 | Re: creating objects in pg_catalog |
Previous Message | Tom Lane | 2012-06-06 21:04:44 | Re: Avoiding adjacent checkpoint records |