ext-postgresql
ext-postgresql copied to clipboard
🐘 Coroutine-based client for PostgreSQL
 ```
/bin/sh /Volumes/Workspaces/ext-postgresql-4.8.0/libtool --mode=link g++ -DPHP_ATOM_INC -I/Volumes/Workspaces/ext-postgresql-4.8.0/include -I/Volumes/Workspaces/ext-postgresql-4.8.0/main -I/Volumes/Workspaces/ext-postgresql-4.8.0 -I/opt/homebrew/Cellar/[email protected]/7.4.29/include/php -I/opt/homebrew/Cellar/[email protected]/7.4.29/include/php/main -I/opt/homebrew/Cellar/[email protected]/7.4.29/include/php/TSRM -I/opt/homebrew/Cellar/[email protected]/7.4.29/include/php/Zend -I/opt/homebrew/Cellar/[email protected]/7.4.29/include/php/ext -I/opt/homebrew/Cellar/[email protected]/7.4.29/include/php/ext/date/lib -I/opt/homebrew/opt/libpq//include -I/Volumes/Workspaces/ext-postgresql-4.8.0 -I/Volumes/Workspaces/ext-postgresql-4.8.0/include -I/opt/homebrew/Cellar/[email protected]/7.4.29/include/php/ext/swoole -I/opt/homebrew/Cellar/[email protected]/7.4.29/include/php/ext/swoole/include -DHAVE_CONFIG_H -Wall -pthread -g -O2 -std=gnu89 -Wl,-rpath,/opt/homebrew/opt/libpq//lib -L/opt/homebrew/opt/libpq//lib -lpthread -o swoole_postgresql.la...
``` make ``` /bin/bash /tmp/ext-postgresql/libtool --mode=compile g++ -I. -I/tmp/ext-postgresql -I/tmp/ext-postgresql/include -I/tmp/ext-postgresql/main -I/tmp/ext-postgresql -I/usr/include/php/20210902 -I/usr/include/php/20210902/main -I/usr/include/php/20210902/TSRM -I/usr/include/php/20210902/Zend -I/usr/include/php/20210902/ext -I/usr/include/php/20210902/ext/date/lib -I/tmp/ext-postgresql -I/tmp/ext-postgresql/include -I/usr/include/php/20210902/ext/swoole -I/usr/include/php/20210902/ext/swoole/include -DHAVE_CONFIG_H -g -O2 -Wall -Wno-unused-function -Wno-deprecated -Wno-deprecated-declarations -std=c++11...
,4.5.9没有找到对应版本下了4.4.18,make的时候编译报错: /usr/local/software/ext-postgresql # make /bin/sh /usr/local/software/ext-postgresql/libtool --mode=compile g++ -I. -I/usr/local/software/ext-postgresql -DPHP_ATOM_INC -I/usr/local/software/ext-postgresql/include -I/usr/local/software/ext-postgresql/main -I/usr/local/software/ext-postgresql -I/usr/local/include/php -I/usr/local/include/php/main -I/usr/local/include/php/TSRM -I/usr/local/include/php/Zend -I/usr/local/include/php/ext -I/usr/local/include/php/ext/date/lib -I/usr/local/software/ext-postgresql -I/usr/local/software/ext-postgresql/include -I/usr/local/include/php/ext/swoole -I/usr/local/include/php/ext/swoole/include -DHAVE_CONFIG_H -g -O2 -Wall -Wno-unused-function -Wno-deprecated...
使用 Swoole V4.8.6 版本安装 ext-postgresql 报错: ``` /mnt/e/code/git/ext-postgresql/swoole_postgresql.cc:282:55: error: macro "SW_INIT_CLASS_ENTRY" passed 5 arguments, but takes just 4 ``` 查了一下是因为在 https://github.com/swoole/swoole-src/commit/32d7c65d9a6add46d97ecd5504317f2121185868#diff-ea09b237f582dcc5832afa83849058ab03b214621160256bd8866bff6c1a6d16L613 中删除了 snake_name 参数。
Hi Team, I faced with strange behaviour when I send incorrect queries. Here are my cases: ```php // Direct SQL query: > INSERT INTO fake_table (id) VALUES (1) [42P01] ERROR:...
The following code produce a segmentation fault. The problem is that the registration of coroutine callbacks were done only in the connect method. I have a fork that fix this...
```php $pg = new \Swoole\Coroutine\PostgreSQL(); $dsn = 'host=localhost;dbname=test;user=user;password=pswd'; $pg->connect($dsn); $res = $pg->query('select name from users where id=1'); $pg->fetchRow($res); // it's ok $res = $pg->query('select name, pg_sleep(4) from users where id=1');...
Hi. PDO have [pgsqlGetNotify](https://www.php.net/manual/en/pdo.pgsqlgetnotify.php) function with second parameter like sleep. How to correct use that function? I wrote some [example code](https://github.com/Gemorroj/swoole-sse/blob/main/server.php) (sse server using listen/notify postgres functionality). See at the...