Re: NOTIFY/LISTEN why is not a callback as notice processing.

From: Михаил Филоненко <filonenko(dot)mikhail(at)gmail(dot)com>
To: pgsql-general(at)postgresql(dot)org
Subject: Re: NOTIFY/LISTEN why is not a callback as notice processing.
Date: 2010-11-12 10:04:14
Message-ID: AANLkTin=W=PML=R14GEjS4yqamHjYZVjsSW1q64yRhoZ@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Thanks. But also I want to use postgresql and gtk with python or with c. I
think, I need to make something like QSocketNotifier with callbacks instead
of signals/slots.

Well, why does libpq accumulate notifi and commit developer to create loop?

select(....)
PQconsumeInput(conn)
while ((notify = PQnotifies(conn)) != NULL)
// show notify

Interface for notice processing provided by libpq is simpler. Notice and
notifies very

receiver(connection, message) {// show notify
}
PQsetNoticeReceiver(receiver);

--
With best regards, Michael Filonenko

In response to

Browse pgsql-general by date

  From Date Subject
Next Message ray 2010-11-12 10:54:06 Help with Stack Builder
Previous Message Vangelis Katsikaros 2010-11-12 10:03:35 Re: ignore errors for COPY [solved]