Re: Running functions that return void in psql

From: Michael Fuhr <mike(at)fuhr(dot)org>
To: Eric Brown <eric(dot)brown(at)propel(dot)com>
Cc: pgsql-general(at)postgresql(dot)org
Subject: Re: Running functions that return void in psql
Date: 2004-12-15 08:47:06
Message-ID: 20041215084706.GB30423@winnie.fuhr.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On Wed, Dec 15, 2004 at 12:19:14AM -0800, Eric Brown wrote:

> I've got quite a few plpgsql functions that insert, update or delete.
> They're all declared to return void. All other functions, I can just
> run 'select f(...);' from psql to test them. I don't understand how to
> test these ones that return void from psql. Thanks.

You could issue queries to verify that the expected inserts, updates,
or deletes (and only those operations) were actually done.

--
Michael Fuhr
http://www.fuhr.org/~mfuhr/

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Eric Brown 2004-12-15 08:48:36 Re: Running functions that return void in psql
Previous Message Neil Conway 2004-12-15 08:43:36 Re: Running functions that return void in psql