aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFujii Masao <fujii@postgresql.org>2014-10-10 03:18:01 +0900
committerFujii Masao <fujii@postgresql.org>2014-10-10 03:18:54 +0900
commit090ad74b00e023ba8af10cc3376b3e5a415de2e7 (patch)
tree61a1dc67afd5401d7f0e4bcb451f7b1eeed1fcdc
parentd3cfe20c6dc498f9294d07c7803a8cc776f8db31 (diff)
downloadpostgresql-090ad74b00e023ba8af10cc3376b3e5a415de2e7.tar.gz
postgresql-090ad74b00e023ba8af10cc3376b3e5a415de2e7.zip
Fix broken example in PL/pgSQL document.
Back-patch to all supported branches. Marti Raudsepp, per a report from Marko Tiikkaja
-rw-r--r--doc/src/sgml/plpgsql.sgml4
1 files changed, 2 insertions, 2 deletions
diff --git a/doc/src/sgml/plpgsql.sgml b/doc/src/sgml/plpgsql.sgml
index 6fffec18b70..2abc4f724bd 100644
--- a/doc/src/sgml/plpgsql.sgml
+++ b/doc/src/sgml/plpgsql.sgml
@@ -486,8 +486,8 @@ $$ LANGUAGE plpgsql;
CREATE FUNCTION extended_sales(p_itemno int)
RETURNS TABLE(quantity int, total numeric) AS $$
BEGIN
- RETURN QUERY SELECT quantity, quantity * price FROM sales
- WHERE itemno = p_itemno;
+ RETURN QUERY SELECT s.quantity, s.quantity * s.price FROM sales AS s
+ WHERE s.itemno = p_itemno;
END;
$$ LANGUAGE plpgsql;
</programlisting>