An unofficial DuckDB communication library for PHP.
You can install the package via composer:
composer require kambo/duckdb kambo/duckdb-php-linux-lib
Note: the kambo/duckdb-php-linux-lib package contains a binary library for Linux.
$database = new Kambo\DuckDB\Database();
$connection = new Kambo\DuckDB\Connection($database);
$connection->query('CREATE TABLE integers(i INTEGER, j INTEGER);');
$connection->query('INSERT INTO integers VALUES (3,4), (5,6), (7, NULL) ');
$result = $connection->query('SELECT * FROM integers;');
var_export($result->toArray());
- This library is in alpha version.
- It currently only works under Linux (work is ongoing for other platforms).
- It has limited support of DuckDB APIs.
composer test
Please see CHANGELOG for more information on what has changed recently.
The MIT License (MIT). Please see License File for more information.