PL/pgSQL: FOUND not set by EXECUTE?

From: Brendan Jurd <blakjak(at)blakjak(dot)sytes(dot)net>
To: PostgreSQL-general <pgsql-general(at)postgresql(dot)org>
Subject: PL/pgSQL: FOUND not set by EXECUTE?
Date: 2004-05-24 09:55:24
Message-ID: 40B1C68C.6040700@blakjak.sytes.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Hello all,

I've discovered that in 7.4.2 PL/pgSQL, the FOUND variable is not at all
affected by use of the EXECUTE command, even if the statement you pass
to EXECUTE would set FOUND to true when run directly. The documentation
doesn't really point this out, and in my opinion, it's an unintuitive
behaviour. Why would executing the command dynamically make a
difference to how FOUND is treated? The statement still "happens" in
the end, additional query plan or no.

Could someone please clarify?

Regards,

Brendan Jurd

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Matthias Nagl 2004-05-24 12:39:55 Combining several rows
Previous Message Tom Lane 2004-05-24 06:27:37 Re: dump / restore questions