X-Original-To: pgsql-sql-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.144]) by svr1.postgresql.org (Postfix) with ESMTP id EE79E329E3B for ; Thu, 16 Sep 2004 04:57:53 +0100 (BST) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 17549-07 for ; Thu, 16 Sep 2004 03:57:48 +0000 (GMT) Received: from stark.xeocode.com (gsstark.mtl.istop.com [66.11.160.162]) by svr1.postgresql.org (Postfix) with ESMTP id C14AA329E39 for ; Thu, 16 Sep 2004 04:57:48 +0100 (BST) Received: from localhost ([127.0.0.1] helo=stark.xeocode.com) by stark.xeocode.com with smtp (Exim 3.36 #1 (Debian)) id 1C7nOt-0007Js-00; Wed, 15 Sep 2004 23:57:39 -0400 To: "Iain" Cc: "Mike Rylander" , Subject: Re: implementing an out-of-transaction trigger References: <002f01c49ad0$9491e180$7201a8c0@mst1x5r347kymb> <008c01c49b91$361e86f0$7201a8c0@mst1x5r347kymb> In-Reply-To: <008c01c49b91$361e86f0$7201a8c0@mst1x5r347kymb> From: Greg Stark Organization: The Emacs Conspiracy; member since 1992 Date: 15 Sep 2004 23:57:39 -0400 Message-ID: <87sm9irhl8.fsf@stark.xeocode.com> Lines: 18 User-Agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.3 MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, hits=0.0 tagged_above=0.0 required=5.0 tests= X-Spam-Level: X-Archive-Number: 200409/113 X-Sequence-Number: 18959 "Iain" writes: > Though, as far as I can tell, there is no way to have the notify activate a > pl/pgsql function directly. I'll still need to write a client program to > create a session and actually do the listening, that is if I havn't missed > anything else... Right, presumably some sort of daemon that sits and waits for events. Much like you would have with Oracle advanced queuing and such. The big difference is that NOTIFY doesn't pass along any parameters. You will need some way for your daemon to find any pending data it needs to process. You might need some kind of queue table, or you might be able to get by without one. -- greg