From: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
---|---|
To: | John Gray <jgray(at)azuli(dot)co(dot)uk> |
Cc: | Hackers List <pgsql-hackers(at)postgresql(dot)org>, Christopher Kings-Lynne <chriskl(at)familyhealth(dot)com(dot)au> |
Subject: | Re: commands subdirectory continued -code cleanup |
Date: | 2002-04-19 19:34:12 |
Message-ID: | 2992.1019244852@sss.pgh.pa.us |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
John Gray <jgray(at)azuli(dot)co(dot)uk> writes:
> Sequences still seem to work after they've had attributes renamed, but I
> see little value in being able to do this. Is it OK to prohibit the
> renaming of sequence columns?
That seems like an error to me. Setting defaults, constraints, etc on a
sequence is bogus too --- do we catch those?
> There are also permissions checks made in tcop/utility.c before
> AlterTableOwner and renamerel are called. It may be best to move these
> into commands/tablecmds.c. It seems that tcop/utility.c was supposed to
> handle the permissions checks for statements, but the inheritance
> support has pushed some of that into commands/ . Should permissions
> checking for other utility statements be migrated to commands/ for
> consistency? I don't propose to do this now -but it might be a later
> stage in the process.
Not sure. There are subroutines in utility.c that are useful for
this purpose, and I don't really see the value of having them called
from all over the place when it can be more localized. We should
probably be consistent about having tablecmds.c make all the relevant
permissions checks for its operations, but I don't think that
necessarily translates into the same choice for the rest of commands/.
AFAIR none of the rest of commands/ has the recursive-operations issue
that forces this approach for table commands.
regards, tom lane
From | Date | Subject | |
---|---|---|---|
Next Message | Fernando Nasser | 2002-04-19 19:38:07 | Re: commands subdirectory continued -code cleanup |
Previous Message | jtp | 2002-04-19 19:14:03 | general design question |