Search by

efabrica / phoenix-pdo

dev-efabrica

Shared PDO base (abstract adapter, statement wrapper, factory) for Phoenix database migration adapters

Package info

github.com/efabrica-team/phoenix-pdo

pkg:composer/efabrica/phoenix-pdo

Statistics

Installs: 123

Dependents: 2

Suggesters: 0

Stars: 0

Open Issues: 0

1.0.0 2026-10-23 12:57 UTC

This package is auto-updated.

Last update: 2026-10-26 08:43:54 UTC


README

Shared PDO base for Phoenix database migration adapters: the abstract Phoenix\Database\Adapter\Pdo\PdoAdapter, PdoStatementWrapper (StatementInterface on top of PDOStatement) and the abstract PdoAdapterFactory.

This package registers no adapter by itself. Install one of the adapters built on it:

composer require efabrica/phoenix-core efabrica/phoenix-mysql

Own PDO based adapter

Extend PdoAdapter (implement the vendor specific parts: query builder, structure loading, escaping) and PdoAdapterFactory (getAdapterName() and createAdapter()), then register the factory via Phoenix\Database\Adapter\AdapterFactory::registerFactory() from a composer autoload.files bootstrap. See efabrica/phoenix-mysql for a complete example.

Tests

Tests run on an in-memory SQLite database (ext-pdo_sqlite), no database server is needed.