Re: Oracle PL/SQL Anonymous block equivalent in postgres

From: "Jim C(dot) Nasby" <jnasby(at)pervasive(dot)com>
To: Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>
Cc: Hannu Krosing <hannu(at)skype(dot)net>, Ashok(dot)Agrawal(at)Sun(dot)COM, pgsql-hackers(at)postgresql(dot)org
Subject: Re: Oracle PL/SQL Anonymous block equivalent in postgres
Date: 2005-12-27 17:18:59
Message-ID: 20051227171859.GF72143@pervasive.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Thu, Dec 22, 2005 at 06:35:24PM -0500, Bruce Momjian wrote:
> Hannu Krosing wrote:
> > ?hel kenal p?eval, N, 2005-12-22 kell 18:19, kirjutas Bruce Momjian:
> > I guess he rather wants to have dont-save-but-execute-immediately
> > pl/pgsql code.
> >
> > could this perhaps be solved by having temporary functions, similar to
> > postgresql's temporary tables ?
>
> I am thinking they want the ability to sit at a prompt and type stuff.

FWIW, I would find the ability to run stuff from the prompt useful for
debugging plpgsql functions. Rather than

edit function def
CREATE OR REPLACE FUNCTION ...
test function

you could just edit in-place and test.

Of course having the ability to execute arbitrary plpgsql in .sql
scripts would be handy in some cases as well, though as others pointed
out there are alternatives.
--
Jim C. Nasby, Sr. Engineering Consultant jnasby(at)pervasive(dot)com
Pervasive Software http://pervasive.com work: 512-231-6117
vcard: http://jim.nasby.net/pervasive.vcf cell: 512-569-9461

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Bruce Momjian 2005-12-27 17:45:07 Re: [HACKERS] Online backup vs Continuous backup
Previous Message Jim C. Nasby 2005-12-27 17:07:29 Re: [Bizgres-general] WAL bypass for INSERT, UPDATE and