Re: WIP: updatable cursors in plpgsql

From: "Pavel Stehule" <pavel(dot)stehule(at)gmail(dot)com>
To: "Tom Lane" <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: pgsql-patches(at)postgresql(dot)org
Subject: Re: WIP: updatable cursors in plpgsql
Date: 2007-06-11 14:52:15
Message-ID: 162867790706110752h4883744bg5a02bf25de8c806c@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-patches

2007/6/11, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>:
> "Pavel Stehule" <pavel(dot)stehule(at)gmail(dot)com> writes:
> > this small patch allows using updatable cursors in plpgsql.
>
> Why do we need this?
>
For stored procedures. Updatable cursors are used mainly in transform
procedures, and without suppport in plpgsql, you have to write
external procedure. It similar with support scrollable cursors, which
was added into plpgsql now. It's not strong argument. With this patch
will be less diference between cursors supported by PostgreSQL and
cursors in plpgsql.

Updatable cursor are currently substituted using ctid, but updatable
cursors are more clean and readable.

PL/pgSQL can be consistent in support PostgreSQL SQL statements. It's
little bit strange, PostgreSQL offer some functionality, which cannot
be used from PL/pgSQL.

Regards
Pavel Stehule

In response to

Responses

Browse pgsql-patches by date

  From Date Subject
Next Message Andrew Dunstan 2007-06-11 14:59:48 Re: COPYable logs status
Previous Message Tom Lane 2007-06-11 14:03:40 Re: WIP: updatable cursors in plpgsql