Re: SQL/MED - core functionality

From: Shigeru HANADA <hanada(at)metrosystems(dot)co(dot)jp>
To: Robert Haas <robertmhaas(at)gmail(dot)com>
Cc: pgsql-hackers(at)postgresql(dot)org
Subject: Re: SQL/MED - core functionality
Date: 2011-01-05 05:52:07
Message-ID: 20110105145206.30FD.6989961C@metrosystems.co.jp
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Sat, 1 Jan 2011 23:54:05 -0500
Robert Haas <robertmhaas(at)gmail(dot)com> wrote:
> On Mon, Dec 27, 2010 at 10:16 PM, Robert Haas <robertmhaas(at)gmail(dot)com> wrote:
> > On Sat, Dec 25, 2010 at 11:52 PM, Robert Haas <robertmhaas(at)gmail(dot)com> wrote:
> >> I'm working on getting a first chunk of this committed.
> >
> > OK, here's the patch.
>
> I've now committed a version of this with a bunch of further
> revisions, corrections, and cleanup. It looks to me as though this
> patch was written based on the 9.0 code and not thoroughly updated for
> some of the 9.1 changes, but I think I cleaned most of that up. With
> a patch of this size, I am sure there are a few things I overlooked,
> so please point 'em out and I'll try to fix them promptly.

While testing the commit, I found that CREATE FOREIGN TABLE requires
unnecessary USAGE privilege on the FOREIGN DATA WRAPPER. SQL/MED
standard requires only USAGE on the SERVER as follows.

<quote>
1) If <foreign table definition> is contained in an SQL-client module,
then the enabled authorization identifiers shall include A.

2) The applicable privileges shall include the USAGE privilege on the
foreign-server identified by <foreign server name>.

3) Additional privileges, if any, necessary to execute <foreign table
definition> are implementation-defined.
</quote>

Sorry, this problem comes from original patch.
OTOH, the document about this specification which is written in "GRANT"
page is correct.

Regards,
--
Shigeru Hanada

Attachment Content-Type Size
20110105-no_fdw_check.patch application/octet-stream 575 bytes

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Jeff Davis 2011-01-05 05:54:16 Re: WIP: Range Types
Previous Message Joshua D. Drake 2011-01-05 04:13:38 Re: making an unlogged table logged