This package is abandoned and no longer maintained. The author suggests using the spiral/database package instead.

DBAL, schema introspection, migration and pagination

v2.7.13 2020-06-22 02:09 UTC


Interacting with databases extremely simple across a variety of database backends using either raw SQL, the fluent query builder, and the DBAL. Currently, this package is a fork version of Spiral Database to be used as standalone in any php project.

Please note that you can get the documentation for this dependency on spiral website, database



The recommended way to install Database Manager is via Composer:

composer require biurad/biurad-database

It requires PHP version 7.2 and supports PHP up to 7.4. The dev-master version requires PHP 7.1. Also PDO Extension with desired database drivers.

How To Use


Given example demonstrates the connection to SQLite database, creation of table schema, data insertion and selection:


require_once "vendor/autoload.php";

use BiuradPHP\Database\Config\DatabaseConfig;
use BiuradPHP\Database\DatabaseManager;
use BiuradPHP\Database\Driver\SQLite\SQLiteDriver;

$dbm = new DatabaseManager(new DatabaseConfig([
    'databases'   => [
        'default' => ['connection' => 'sqlite'],
    'connections' => [
        'sqlite' => [
            'driver'     => SQLiteDriver::class,
            'connection' => 'sqlite:database.db',

$users = $dbm->database('default')->table('users');

// create or update table schema
$schema = $users->getSchema();

// insert data
    'name'       => 'test',
    'created_at' => new DateTimeImmutable(),
    'updated_at' => new DateTimeImmutable(),

// select data
foreach ($users->select()->where(['name' => 'test']) as $u) {


Please see CHANGELOG for more information what has changed recently.


Please see CONTRIBUTING for details.


To run the tests you'll have to start the included node based server if any first in a separate terminal window.

With the server running, you can start testing.



If you discover any security related issues, please report using the issue tracker. use our example Issue Report template.

Want to be listed on our projects website

You're free to use this package, but if it makes it to your production environment we highly appreciate you sending us a message on our website, mentioning which of our package(s) you are using.

Post Here: Project Patreons -

We publish all received request's on our website.


Support us

Biurad Lap is a technology agency in Accra, Ghana. You'll find an overview of all our open source projects on our website.

Does your business depend on our contributions? Reach out and support us on to build more project's. We want to build over one hundred project's in two years. Support Us achieve our goal.

Reach out and support us on Patreon. All pledges will be dedicated to allocating workforce on maintenance and new awesome stuff.

Thanks to all who made Donations and Pledges to Us.


MIT License (MIT). Please see LICENSE for more information. Maintained by Spiral Scout.