From: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
---|---|
To: | Cott Lang <cott(at)internetstaff(dot)com>, pgsql-general(at)postgresql(dot)org |
Subject: | Re: Fixing invalid owners on pg_toast tables in 8.3.5 |
Date: | 2009-02-21 17:30:50 |
Message-ID: | 27254.1235237450@sss.pgh.pa.us |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general |
I wrote:
> [ scratches head... ] That example fails to misbehave for me in 8.3.6,
Oh, wait, you omitted a step from the example: the ALTER has to be done
as somebody other than the table owner (eg a superuser, else you'd not
have the needed permissions).
regression=# create user a;
CREATE ROLE
regression=# \c - a
psql (8.4devel)
You are now connected to database "regression" as user "a".
regression=> create table toaster (
bread varchar(7000));
CREATE TABLE
regression=> select typowner from pg_type join pg_class on (typname=relname) where
pg_class.oid in (select reltoastrelid from pg_class where
relname='toaster');
typowner
----------
63977
(1 row)
regression=> \c - postgres
psql (8.4devel)
You are now connected to database "regression" as user "postgres".
regression=# alter table toaster ALTER bread type varchar(9000);
ALTER TABLE
regression=# select typowner from pg_type join pg_class on (typname=relname) where
pg_class.oid in (select reltoastrelid from pg_class where
relname='toaster');
typowner
----------
10
(1 row)
Yeah, that's a bug. It probably hasn't got anything to do with the
other toast-table weirdnesses we've heard about, but it's a bug.
regards, tom lane
From | Date | Subject | |
---|---|---|---|
Next Message | Tom Lane | 2009-02-21 17:44:55 | Re: Pointers in custom types |
Previous Message | Will Harrower | 2009-02-21 17:28:42 | Pointers in custom types |