Skip to content

Commit f19f0ee

Browse files
committed
Fix broken example in PL/pgSQL document.
Back-patch to all supported branches. Marti Raudsepp, per a report from Marko Tiikkaja
1 parent 7b1c2a0 commit f19f0ee

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

doc/src/sgml/plpgsql.sgml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -487,8 +487,8 @@ $$ LANGUAGE plpgsql;
487487
CREATE FUNCTION extended_sales(p_itemno int)
488488
RETURNS TABLE(quantity int, total numeric) AS $$
489489
BEGIN
490-
RETURN QUERY SELECT quantity, quantity * price FROM sales
491-
WHERE itemno = p_itemno;
490+
RETURN QUERY SELECT s.quantity, s.quantity * s.price FROM sales AS s
491+
WHERE s.itemno = p_itemno;
492492
END;
493493
$$ LANGUAGE plpgsql;
494494
</programlisting>

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy