postgres.git / summary / log / commit / refs
commit 6f94280dee9f8b6c511f00a50531b981faa73b54
Author: Bruce Momjian <bruce@momjian.us>
Date: Tue Sep 06 17:41:28 2011 +0000
First released in: 9.2.0, 9.0.5, 9.1.0
Document PERFORM limitation when using WITH queries.
Backpatch to 9.0 and 9.1.
Report from depstein@alliedtesting.com.
doc/src/sgml/plpgsql.sgml | 3 +++
1 file changed, 3 insertions(+)
diff --git a/doc/src/sgml/plpgsql.sgml b/doc/src/sgml/plpgsql.sgml
index 08c3658d5e3..a2482de2b95 100644
--- a/doc/src/sgml/plpgsql.sgml
+++ b/doc/src/sgml/plpgsql.sgml
@@ -940,6 +940,9 @@ PERFORM <replaceable>query</replaceable>;
result. Write the <replaceable>query</replaceable> the same
way you would write an SQL <command>SELECT</> command, but replace the
initial keyword <command>SELECT</> with <command>PERFORM</command>.
+ For <keyword>WITH</> queries, use <keyword>PERFORM</> and then
+ place the query in parentheses. (In this case, the query can only
+ return one row.)
<application>PL/pgSQL</application> variables will be
substituted into the query just as for commands that return no result,
and the plan is cached in the same way. Also, the special variable
[parent: ae92eff6b93c]