how to loop until eof in a cursor with pgsql

From: "Thomas Radnetter" <tr75(at)gmx(dot)net>
To: pgsql-general(at)postgresql(dot)org
Subject: how to loop until eof in a cursor with pgsql
Date: 2005-06-07 15:40:08
Message-ID: 20136.1118158808@www6.gmx.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

hi folks,

any idea how to loop through a cursor until it's eof?

i'll try to do it this way:

declare cursor ..... (with param)

open cursor .... (param);
fetch into record ....

while found
... anything here
fetch into record
end loop

am i right? can not try it at the moment.

any suggestions?

thanx,
tom

--
Geschenkt: 3 Monate GMX ProMail gratis + 3 Ausgaben stern gratis
++ Jetzt anmelden & testen ++ http://www.gmx.net/de/go/promail ++

Browse pgsql-general by date

  From Date Subject
Next Message John Barham 2005-06-07 15:42:40 Recovery when old WAL segment has been overwritten?
Previous Message Phil Endecott 2005-06-07 15:35:31 Re: CPU-intensive autovacuuming