Skip site navigation (1) Skip section navigation (2)

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 (view raw or flat)
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

pgsql-hackers by date

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

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group