1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52
|
<!-- manual page source format generated by PolyglotMan v3.0.4, -->
<!-- available via anonymous ftp from ftp.cs.berkeley.edu:/ucb/people/phelps/tcltk/rman.tar.Z -->
<HTML>
<HEAD>
<TITLE>"NOTIFY"(SQL) manual page</TITLE>
</HEAD>
<BODY>
<A HREF="sql.html">SQL Reference Contents</A>
<H2><A NAME="sect0" HREF="#toc0">NAME </A></H2>
notify - signal all frontends and backends listening on a class
<H2><A NAME="sect1" HREF="#toc1">SYNOPSIS </A></H2>
<B>notify </B> class_name <BR>
<H2><A NAME="sect2" HREF="#toc2">DESCRIPTION </A></H2>
<B>notify</B> is used to awaken all
backends and consequently all frontends that have executed <I><A HREF="listen.l.html">listen</I>(l)</A>
on <I>class_name</I>. This can be used either within an instance-level rule as
part of the action body or from a normal query. When used from within
a normal query, this can be thought of as interprocess communication (IPC).
When used from within a rule, this can be thought of as an alerter mechanism.
<P>
Notice that the mere fact that a <B>notify</B> has been executed does not imply
anything in particular about the state of the class (e.g., that it has been
updated), nor does the notification protocol transmit any useful information
other than the class name. Therefore, all <B>notify</B> does is indicate that
some backend wishes its peers to examine <I>class_name</I> in some application-specific
way. <P>
This event notification is performed through the Libpq protocol and
frontend application interface. The application program must explicitly
poll a Libpq global variable, <I>PQAsyncNotifyWaiting</I>, and call the routine
<I>PQnotifies</I> in order to find out the name of the class to which a given
notification corresponds. If this code is not included in the application,
the event notification will be queued and never be processed.
<H2><A NAME="sect3" HREF="#toc3">SEE ALSO
</A></H2>
define <A HREF="rule.l.html">rule(l)</A>
, <A HREF="listen.l.html">listen(l)</A>
, libpq. <P>
<HR><P>
<A NAME="toc"><B>Table of Contents</B></A><P>
<UL>
<LI><A NAME="toc0" HREF="#sect0">NAME</A></LI>
<LI><A NAME="toc1" HREF="#sect1">SYNOPSIS</A></LI>
<LI><A NAME="toc2" HREF="#sect2">DESCRIPTION</A></LI>
<LI><A NAME="toc3" HREF="#sect3">SEE ALSO</A></LI>
</UL>
</BODY></HTML>
|