Location via proxy:
[ UP ]
[Report a bug]
[Manage cookies]
No cookies
No scripts
No ads
No referrer
Show this form
projects
/
postgresql.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
037b912
)
Fix broken example in PL/pgSQL document.
author
Fujii Masao
<fujii@postgresql.org>
Thu, 9 Oct 2014 18:18:01 +0000
(
03:18
+0900)
committer
Fujii Masao
<fujii@postgresql.org>
Thu, 9 Oct 2014 18:19:05 +0000
(
03:19
+0900)
Back-patch to all supported branches.
Marti Raudsepp, per a report from Marko Tiikkaja
doc/src/sgml/plpgsql.sgml
patch
|
blob
|
blame
|
history
diff --git
a/doc/src/sgml/plpgsql.sgml
b/doc/src/sgml/plpgsql.sgml
index 0a9d71ef41a5f079274c30b4236fbd412d2991db..d1d66c209354c767b670c82efbaa84f778688b48 100644
(file)
--- 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 sale
s
- 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>