Re: NOTIFY/LISTEN Using Embedded SQL (ecpg) - Mailing list pgsql-general

From Richard Huxton
Subject Re: NOTIFY/LISTEN Using Embedded SQL (ecpg)
Date
Msg-id 003801c0e364$dc3e9ea0$1001a8c0@archonet.com
Whole thread Raw
In response to NOTIFY/LISTEN Using Embedded SQL (ecpg)  ("Craig Orsinger" <cjorsinger@m5.earthlink_net.invalid>)
List pgsql-general
From: "Craig Orsinger" <cjorsinger@m5.earthlink_net.invalid>
To: <pgsql-general@postgresql.org>
Sent: Tuesday, May 22, 2001 6:08 PM
Subject: [GENERAL] NOTIFY/LISTEN Using Embedded SQL (ecpg)


> [cross posted from comp.databases.postgresql.general]
>
>      So, it appears that I can set up my program to LISTEN or
> UNLISTEN using embedded SQL, but I can't get a notification when
> it's sent. Or so I think. _Is_ there a way to get the libpq connection
info
> from the ESQL CONNECT call?
>
>     Does anyone have a suggestion (other than completely rewriting
> my application in libpq calls)? Pointers to any examples of how
> this is done would be especially helpful, but any hints would be
> appreciated.

Can you not just wrap up the libpq stuff in it's own module? A "LISTEN X"
doesn't have to be on any particular connection. Don't know whether opening
another connection per program is practical for you.

- Richard Huxton


pgsql-general by date:

Previous
From: "Richard Huxton"
Date:
Subject: Re: incomplete transaction keeps table locked?
Next
From: "Richard Huxton"
Date:
Subject: Re: can't start as root