Re: GRANT ON ALL IN schema - Mailing list pgsql-hackers

From Peter Eisentraut
Subject Re: GRANT ON ALL IN schema
Date
Msg-id 1250378139.18992.6.camel@vanquo.pezone.net
Whole thread Raw
In response to Re: GRANT ON ALL IN schema  (Sam Mason <sam@samason.me.uk>)
Responses Re: GRANT ON ALL IN schema  (Sam Mason <sam@samason.me.uk>)
Re: GRANT ON ALL IN schema  (Robert Haas <robertmhaas@gmail.com>)
List pgsql-hackers
On lör, 2009-08-15 at 23:31 +0100, Sam Mason wrote:
> On Sat, Aug 15, 2009 at 11:34:04PM +0200, Dimitri Fontaine wrote:
> > Nitpicking dept, I think I prefer:
> > 
> >  DO [ [LANGUAGE] language] $$ ... $$;
> >  DO plperl $$ ... $$;
> >  DO language plpython $$ ... $$;
> > 
> > language is optional and defaults to plpgsql.
> 
> Yup, sounds nicer.  The less globals the better!
> 
> Next all you need is to be able to PREPARE them (and somehow access the
> parameters from execute) and you'll have nice local functions. :)

Yeah, rather than just making up some new command for "execute this
string", this could be generalized as lambda expressions that could be
called whereever an expression is allowed.  E.g.

SELECT LAMBDA $$ ... $$;

-- if CALL is implemented
CALL LAMBDA $$ ... $$;

PREPARE foo AS SELECT LAMBDA $$ ... $$;
EXECUTE foo;

SELECT (LAMBDA (x int, y text) $$ ... $$) (37, 'foo');



pgsql-hackers by date:

Previous
From: Andrew Dunstan
Date:
Subject: Re: [COMMITTERS] pgsql: Remove tabs from SGML.
Next
From: Peter Eisentraut
Date:
Subject: Re: [COMMITTERS] pgsql: Remove tabs from SGML.