Loop plpgsql recordset - Mailing list pgsql-general

From Furesz Peter
Subject Loop plpgsql recordset
Date
Msg-id 003501c740b9$8814a410$6500a8c0@bixerverintel
Whole thread Raw
Responses Re: Loop plpgsql recordset
Re: Loop plpgsql recordset
List pgsql-general
Hello,

How can I loop a PL/PgSQL recorset variable? The example:

    DECLARE
        v_tmp_regi RECORD;
        v_tmp RECORD;
    BEGIN
      SELECT * INTO v_tmp_regi FROM sulyozas_futamido sf WHERE
sf.termekfajta_id=
      a_termekfajta_id AND sf.marka_id=a_marka_id;

        DELETE FROM sulyozas_futamido;

        FOR v_tmp IN v_tmp_regi LOOP
            --I would like to work here with the old recordset!
        END LOOP;
        ^^^^^^^^^^^^^^
       -- This is not working !!!

    END;

pgsql-general by date:

Previous
From: "Kai Schlamp"
Date:
Subject: relationship in a table
Next
From: Inoqulath
Date:
Subject: SQL Newbie Question