Thread: Cursors in PL/pgSQL

Cursors in PL/pgSQL

From
Rob
Date:
Is there any way to declare a cursor in  PL/pgSQL.

Basically I need to write a store proc that cycles through a table row by
row and terminates at the last row.  Do I have to write it in  using
PL/pgSQL (PL/pgSQL won't let me use many of the normal sql keywords) and,
if I do, how do I cycle through a table?

Thanks

Rob

--
He who dies with the most toys ...

                    ... still dies


Re: Cursors in PL/pgSQL

From
Tom Lane
Date:
Rob <rob@obsidian.co.za> writes:
> Is there any way to declare a cursor in  PL/pgSQL.

In 7.2, yes.

            regards, tom lane