Re: pgsql and cursor

From: Ian Lance Taylor <ian(at)airs(dot)com>
To: Najm Hashmi <najm(at)mondo-live(dot)com>
Cc: pgsql <pgsql-sql(at)postgresql(dot)org>
Subject: Re: pgsql and cursor
Date: 2001-02-09 21:17:34
Message-ID: si8znfh7yp.fsf@daffy.airs.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-sql

Najm Hashmi <najm(at)mondo-live(dot)com> writes:

> Hi all, I am not sure If it is allowed to use cursor inside pgsql functions.
> If it is possible, please someone could send exact synatx how it is used. If
> it is not allowed is there a way arround it? I need to do some calculations
> and then return this value as text.

Cursors are not supported in PL/pgSQL. (You can, however, use FOR to
loop over a query).

For a patch to add cursor support to PL/pgSQL, see
http://www.airs.com/ian/pgsql-cursor.html

Ian

In response to

Browse pgsql-sql by date

  From Date Subject
Next Message Stephan Szabo 2001-02-09 21:21:08 Re: String Concatnation
Previous Message plpgsql 2001-02-09 21:17:03 Re: What's wrong with this function