summaryrefslogtreecommitdiff
path: root/ext/pgsql/tests/pg_get_notify.inc
blob: dfb4fe3b859c8dd1e8086f683bec60ac94e3e033 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
<?php
// optional functions

include('config.inc');


$db = pg_connect($conn_str);
pg_query($db, 'LISTEN test_msg');
pg_query($db, 'NOTIFY test_msg');

$msg = pg_get_notify($db);

isset($msg['message'],$msg['pid']) ? print 'OK' : print 'NG';


?>