aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTom Lane <tgl@sss.pgh.pa.us>2006-03-08 22:59:17 +0000
committerTom Lane <tgl@sss.pgh.pa.us>2006-03-08 22:59:17 +0000
commit0a5c6fadf4e98e069263927a6ffaea9758962dbd (patch)
tree59c3d49b41f030d33c1567751246e343af5866d4
parenta0af608adcd52b873fea1c446576b224a8b3e74d (diff)
downloadpostgresql-0a5c6fadf4e98e069263927a6ffaea9758962dbd.tar.gz
postgresql-0a5c6fadf4e98e069263927a6ffaea9758962dbd.zip
Remove somebody's flight of fancy about an UPDATE with ORDER BY and LIMIT.
-rw-r--r--doc/src/sgml/ref/update.sgml16
1 files changed, 1 insertions, 15 deletions
diff --git a/doc/src/sgml/ref/update.sgml b/doc/src/sgml/ref/update.sgml
index ff8f1337e4c..f642b3c8e6d 100644
--- a/doc/src/sgml/ref/update.sgml
+++ b/doc/src/sgml/ref/update.sgml
@@ -1,5 +1,5 @@
<!--
-$PostgreSQL: pgsql/doc/src/sgml/ref/update.sgml,v 1.33.2.1 2006/01/19 23:09:46 momjian Exp $
+$PostgreSQL: pgsql/doc/src/sgml/ref/update.sgml,v 1.33.2.2 2006/03/08 22:59:17 tgl Exp $
PostgreSQL documentation
-->
@@ -217,20 +217,6 @@ UPDATE employees SET sales_count = sales_count + 1 WHERE id =
</para>
<para>
- Now that all the papers are signed, update the most recently closed
- deal of the travelling salesperson who closed the Rocket Powered
- Skates deal with the Acme Corporation.
-<programlisting>
-UPDATE employees SET last_closed_deal = deal.id
- FROM accounts JOIN deals ON (account.id = deal.account_id)
- WHERE deal.employee_id = employees.id
- AND deal.name = 'Rocket Powered Skates'
- AND accounts.name = 'Acme Corporation'
- ORDER BY deal.signed_date DESC LIMIT 1;
-</programlisting>
- </para>
-
- <para>
Attempt to insert a new stock item along with the quantity of stock. If
the item already exists, instead update the stock count of the existing
item. To do this without failing the entire transaction, use savepoints.