Re: tsearch_core patch: permissions and security issues

Robert Treat <xzilla@users.sourceforge.net>

From: Robert Treat <xzilla@users.sourceforge.net>
To: pgsql-hackers@postgresql.org
Cc: Oleg Bartunov <oleg@sai.msu.su>, Tom Lane <tgl@sss.pgh.pa.us>, Gregory Stark <stark@enterprisedb.com>, Teodor Sigaev <teodor@sigaev.ru>
Date: 2007-06-15T11:42:06Z
Lists: pgsql-hackers
On Friday 15 June 2007 00:46, Oleg Bartunov wrote:
> On Thu, 14 Jun 2007, Tom Lane wrote:
> > [ thinks some more... ]  If we revived the GENERATED AS patch,
> > you could imagine computing tsvector columns via "GENERATED AS
> > to_tsvector('english'::regconfig, big_text_col)" instead of a
> > trigger, and then again you've got the dependency exposed where
> > the system can see it.  I don't wanna try to do that for 8.3,
> > but it might be a good path to pursue in future, instead of assuming
> > that triggers will be the way forevermore.
> >
> > Thoughts?
>
> No way with standard. GENERATED AS says that "all columns references in an
> expression associated with a generated column must be to columns of the
> base table containing that generated column."
>
> tsvector could be result of rather complex select involving several tables.
>

Is there some reason for this restriction in the standard?  I might be in 
favor of "extending" the standard to allow this case if not.  

-- 
Robert Treat
Build A Brighter LAMP :: Linux Apache {middleware} PostgreSQL