Better document INSTEAD behavior for rules.
authorBruce Momjian
Thu, 4 Mar 2004 14:32:12 +0000 (14:32 +0000)
committerBruce Momjian
Thu, 4 Mar 2004 14:32:12 +0000 (14:32 +0000)
doc/src/sgml/ref/create_rule.sgml

index fbaa16cecdc0b2cd90083384daa132eb9514f2b2..412ebcd66b63b93dd480148e0ebf4e5a03d918ed 100644 (file)
@@ -1,5 +1,5 @@
 
 
@@ -42,15 +42,15 @@ CREATE [ OR REPLACE ] RULE name AS
    define an alternate action to be performed on insertions, updates,
    or deletions in database tables.  Roughly speaking, a rule causes
    additional commands to be executed when a given command on a given
-   table is executed.  Alternatively, a rule can replace a given
-   command by another, or cause a command not to be executed at all.
-   Rules are used to implement table views as well.  It is important
-   to realize that a rule is really a command transformation
-   mechanism, or command macro.  The transformation happens before the
-   execution of the commands starts.  If you actually want an
-   operation that fires independently for each physical row, you
-   probably want to use a trigger, not a rule.  More information about
-   the rules system is in .
+   table is executed.  Alternatively, aINSTEAD
+   rule can replace a given command by another, or cause a command 
+   not to be executed at all.  Rules are used to implement table 
+   views as well.  It is important to realize that a rule is really 
+   a command transformation mechanism, or command macro.  The 
+   transformation happens before the execution of the commands starts.  
+   If you actually want an operation that fires independently for each 
+   physical row, you probably want to use a trigger, not a rule.  
+   More information about the rules system is in .
   
   
   
@@ -140,6 +140,17 @@ CREATE [ OR REPLACE ] RULE name AS
     
    
 
+   
+    
+    
+     
+      INSTEAD indicates that the commands should be
+      executed instead of the original command, not in
+      addition to the original command.
+     
+    
+   
+
    
     command