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

From Craig Orsinger
Subject NOTIFY/LISTEN Using Embedded SQL (ecpg)
Date
Msg-id 20010521.184618.1308044878.10929@epg.lewis.army_mil.invalid
Whole thread Raw
List pgsql-general
I seem to have painted myself into a corner, technologically speaking.
I am implementing a database using embedded SQL, and PostgreSQL
6.5.3 as the backend. The problem is that I would like to use the NOTIFY
feature, but the only way I've found of doing this from within a C
program is to use the 'PQnotifies()' function, which requires a PGconn
connection its first parameter. ESQL doesn't provide this connection
information as far as I can tell.

    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.

pgsql-general by date:

Previous
From: "Erny"
Date:
Subject: Primar keys in tables
Next
From: "Johnny_5555"
Date:
Subject: Simple question for SQL Student