aboutsummaryrefslogtreecommitdiff
path: root/doc/src
diff options
context:
space:
mode:
authorTom Lane <tgl@sss.pgh.pa.us>2001-09-07 20:52:31 +0000
committerTom Lane <tgl@sss.pgh.pa.us>2001-09-07 20:52:31 +0000
commit17c03b30b0f191e62e992dc6af8c995fd2b007a2 (patch)
treeae401bda87878b44bea87c629ac74473c0910378 /doc/src
parent8c55728295421f820920a15750cc2938d360c66c (diff)
downloadpostgresql-17c03b30b0f191e62e992dc6af8c995fd2b007a2.tar.gz
postgresql-17c03b30b0f191e62e992dc6af8c995fd2b007a2.zip
Revert treatment of NOTIFY in rules to its pre-7.1 behavior: notify will
occur unconditionally, even if the rule should otherwise execute conditionally. This is more useful than giving an error, even though it's not truly the correct behavior. Per today's pghackers discussion.
Diffstat (limited to 'doc/src')
-rw-r--r--doc/src/sgml/ref/create_rule.sgml16
1 files changed, 15 insertions, 1 deletions
diff --git a/doc/src/sgml/ref/create_rule.sgml b/doc/src/sgml/ref/create_rule.sgml
index 4d682c8899a..47c029e653d 100644
--- a/doc/src/sgml/ref/create_rule.sgml
+++ b/doc/src/sgml/ref/create_rule.sgml
@@ -1,5 +1,5 @@
<!--
-$Header: /cvsroot/pgsql/doc/src/sgml/ref/create_rule.sgml,v 1.25 2001/09/03 12:57:49 petere Exp $
+$Header: /cvsroot/pgsql/doc/src/sgml/ref/create_rule.sgml,v 1.26 2001/09/07 20:52:30 tgl Exp $
Postgres documentation
-->
@@ -249,6 +249,20 @@ SELECT * FROM emp;
</programlisting></para>
</example>
</para>
+
+ <para>
+ Presently, if a rule contains a NOTIFY query, the NOTIFY will be executed
+ unconditionally --- that is, the NOTIFY will be issued even if there are
+ not any rows that the rule should apply to. For example, in
+ <programlisting>
+CREATE RULE notify_me AS ON UPDATE TO mytable DO NOTIFY mytable;
+
+UPDATE mytable SET name = 'foo' WHERE id = 42;
+ </programlisting>
+ one NOTIFY event will be sent during the UPDATE, whether or not there
+ are any rows with id = 42. This is an implementation restriction that
+ may be fixed in future releases.
+ </para>
</refsect2>
</refsect1>