Document DELETE/UPDATE command tag behavior when triggers are involved.
authorRobert Haas
Mon, 10 Oct 2011 16:53:04 +0000 (12:53 -0400)
committerRobert Haas
Mon, 10 Oct 2011 16:53:04 +0000 (12:53 -0400)
Marti Raudsepp

doc/src/sgml/ref/delete.sgml
doc/src/sgml/ref/update.sgml

index 71ebeda880aa90bf92f7cf23c4a43444a7216fde..6366b158118772359b9f5be0d5c1b82b9e13f0ee 100644 (file)
@@ -206,10 +206,12 @@ DELETE FROM [ ONLY ] table [ [ AS ]
 DELETE count
 
    The count is the number
-   of rows deleted.  If count is
-   0, no rows matched the 
-   class="parameter">condition (this is not considered
-   an error).
+   of rows deleted.  Note that the number may be less than the number of
+   rows that matched the 
+   class="parameter">condition when deletes were
+   suppressed by a BEFORE DELETE trigger.  If 
+   class="parameter">count is 0, no rows were deleted by
+   the query (this is not considered an error).
   
 
   
index ba5af8e884bb1d15d5dfd6efe15aed2ed9abe690..1c0e21536b156decedf9743c9deb51e533589e8f 100644 (file)
@@ -226,10 +226,12 @@ UPDATE [ ONLY ] table [ [ AS ] 
 UPDATE count
 
    The count is the number
-   of rows updated.  If count is
-   0, no rows matched the 
-   class="parameter">condition (this is not considered
-   an error).
+   of rows updated, including matched rows whose values did not change.
+   Note that the number may be less than the number of rows that matched
+   the condition when
+   updates were suppressed by a BEFORE UPDATE trigger.  If
+   count is 0, no rows were
+   updated by the query (this is not considered an error).