Re: pl/pgsql enabled by default - Mailing list pgsql-hackers

From Tom Lane
Subject Re: pl/pgsql enabled by default
Date
Msg-id 16567.1115611221@sss.pgh.pa.us
Whole thread Raw
In response to Re: pl/pgsql enabled by default  (Greg Stark <gsstark@mit.edu>)
Responses Re: pl/pgsql enabled by default  (Greg Stark <gsstark@mit.edu>)
List pgsql-hackers
Greg Stark <gsstark@mit.edu> writes:
> Hm. If you incorrectly mark your function as IMMUTABLE even though it
> has side effects then the planner may indeed collapse this. Does the
> planner know it can't collapse views if the underlying tables aren't
> accessible to the user?

There are no cases where function or view collapsing elides permissions
checks (if you have a counterexample please provide it!!).  They could
change the time at which permissions checks are applied, though; which
has the potential for a REVOKE to not disallow execution of already-
planned queries that ideally it should prevent.  I believe that this
risk will be fixed by the planned forcing of replanning after schema
changes.
        regards, tom lane


pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Re: [PATCHES] Cleaning up unreferenced table files
Next
From: Satoshi Nagayasu
Date:
Subject: Re: Oracle Style packages on postgres