> Is there a way to move a cursor in plpgsql in the same way as in
> regular sql? ...
Wouldn't it be easier to list the parts in a random order (simply ORDER
BY RANDOM()) and then use modulo by number of actors (but there's no
ROWNUM so a loop is needed anyway). Something like...
I think you a
> Hi all,
>
> Is there a way to move a cursor in plpgsql in the same way as in
> regular sql? The function below would like to move the cursor back to
> the start each time the cursor runs out of rows, creating pairs of
> integers that are randomly put together.
>
> The "motivation" for this is
Hi all,
Is there a way to move a cursor in plpgsql in the same way as in
regular sql? The function below would like to move the cursor back to
the start each time the cursor runs out of rows, creating pairs of
integers that are randomly put together.
The "motivation" for this is to randomly ass
-Message d'origine-
> De : Michael Fuhr [mailto:[EMAIL PROTECTED]
> Envoy? : mardi 8 mars 2005 18:29
> ? : Tom Lane
> Cc : FERREIRA William (COFRAMI); pgsql-general@postgresql.org
> Objet : Re: [GENERAL] Move cursor
>
>
> On Tue, Mar 08, 2005 at 12:16:28PM -0500,
Title: RE: [GENERAL] Move cursor
does i hope that CURSOR will be fully implemented soon ?
(or maybe you know an alternative for my problem ? :) )
-Message d'origine-
De : Michael Fuhr [mailto:[EMAIL PROTECTED]]
Envoyé : mardi 8 mars 2005 18:29
À : Tom Lane
Cc : FERREIRA Wi
On Tue, Mar 08, 2005 at 12:16:28PM -0500, Tom Lane wrote:
> Michael Fuhr <[EMAIL PROTECTED]> writes:
> > I don't think PL/pgSQL implements cursors fully.
>
> Its cursor facility is certainly far weaker than what's presently in the
> main SQL language. I think this is at least partly historical ac
Michael Fuhr <[EMAIL PROTECTED]> writes:
> I don't think PL/pgSQL implements cursors fully.
Its cursor facility is certainly far weaker than what's presently in the
main SQL language. I think this is at least partly historical accident
(ie we upgraded the main language and forgot about plpgsql).
On Tue, Mar 08, 2005 at 04:23:37PM +0100, FERREIRA William (COFRAMI) wrote:
> i need to use the MOVE function on a cursor, for extracting special rows.
> the function is written in pl/pgSQL
I don't think PL/pgSQL implements cursors fully. In particular,
I don't see MOVE in the PL/pgSQL parser; I
Title: iterate over refcursor
hi
i need
to use the MOVE function on a cursor, for extracting special
rows.
the
function is written in pl/pgSQL
CREATE
OR REPLACE FUNCTION TEST() RETURNS void AS
$$DECLARE
childCursor CURSOR FOR select
* from ... childRecord
adoc.xdb_c