Re: Calling plSQL functions

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Lonnie Cumberland <lonnie_cumberland(at)yahoo(dot)com>
Cc: pgsql-sql(at)postgresql(dot)org
Subject: Re: Calling plSQL functions
Date: 2001-04-13 19:02:53
Message-ID: 5332.987188573@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-sql

Lonnie Cumberland <lonnie_cumberland(at)yahoo(dot)com> writes:
> Actually I have the need at different places in my functions to
> sometimes work on the list items returned from a query and also have
> the need to just work on the first result returned by a query.

SELECT ... LIMIT 1 will serve the second need. For the first, perhaps
use the FOR ... loop construct in plpgsql.

regards, tom lane

In response to

Browse pgsql-sql by date

  From Date Subject
Next Message Josh Berkus 2001-04-13 20:45:49 Re: Calling plSQL functions
Previous Message Lonnie Cumberland 2001-04-13 18:57:14 Re: Calling plSQL functions