dblink_get_notify — récupère les notifications asynchrones sur une connection
dblink_get_notify() returns setof (notify_name text, be_pid int, extra text)
dblink_get_notify(text connname) returns setof (notify_name text, be_pid int, extra text)
dblink_get_notify récupère les notifications soit
sur une connexion anonyme (sans nom), soit sur une connexion nommée si le
nom est précisé. Pour recevoir des notifications via dblink,
LISTEN doit d'abord être lancé en utilisant
dblink_exec. Pour les détails, voir LISTEN et NOTIFY.
connnameLe nom d'une connexion nommée qui veut récupérer les notifications.
Renvoit setof (notify_name text, be_pid int, extra text)
ou un ensemble vide.
SELECT dblink_exec('LISTEN virtual');
dblink_exec
-------------
LISTEN
(1 row)
SELECT * FROM dblink_get_notify();
notify_name | be_pid | extra
-------------+--------+-------
(0 rows)
NOTIFY virtual;
NOTIFY
SELECT * FROM dblink_get_notify();
notify_name | be_pid | extra
-------------+--------+-------
virtual | 1229 |
(1 row)