PHPackages                             vgait/vgadatabase - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Database &amp; ORM](/categories/database)
4. /
5. vgait/vgadatabase

ActiveLibrary[Database &amp; ORM](/categories/database)

vgait/vgadatabase
=================

This is a database abstraction for easy instantiation and usage of PDO

0.9.1(9y ago)07PHPPHP &gt;=7.1.0

Since Jun 24Pushed 9y ago1 watchersCompare

[ Source](https://github.com/maxpeed/VgaDatabase)[ Packagist](https://packagist.org/packages/vgait/vgadatabase)[ RSS](/packages/vgait-vgadatabase/feed)WikiDiscussions master Synced 4w ago

READMEChangelog (2)Dependencies (2)Versions (4)Used By (0)

VgaDatabase - Yet Another PDO Abstraction Layer
===============================================

[](#vgadatabase---yet-another-pdo-abstraction-layer)

Just use this to save some code. This is not a query builder, ypu still have to write your own SQL commands.

- only tested with MySQL, but is based on PDO so it might just work.

Setup
-----

[](#setup)

Copy the database\_example.ini placed in root folder to wherever, and edit it to fit your needs. Then just point to this file when creating the DatabaseConnection instance.

Usage
-----

[](#usage)

From the DatabaseConnection instance us getQuery() and pass a string to it. Then use in various ways:

> $dbInstance-&gt;connect(); $dbInstance-&gt;getQuery($sql)-&gt;execute();

Also works with prepared statements, just use the names as keys in an array of values.

> $fetchedRows = $dbInstance-&gt;getQuery($sql)-&gt;setValuesSingle($values)-&gt;fetchAsArray()-&gt;execute();

For repeated executions, put the arrays of values in an array.

> $success = $dbInstance-&gt;getQuery($sql)-&gt;setValuesMulti($values)-&gt;inputQuery()-&gt;execute();

Conclusion
----------

[](#conclusion)

> Available as package through composer, just require "vgait/vgadatabase" in your project.

The class manages the connection, thus usage is pretty simple. Fixes will be made as I try this one out in other projects. Also, documentation will be improved over time.

##### Disclaimer:

[](#disclaimer)

I'm just at hobby programmer, and will take no responsibility for how this is used, nor for how well it works. But you are free to use this code anyhow you wish, improve upon it and copy it as you feel fitting. The only restrictions I have is that this code is not just rebranded and sold "as is". Also, this code may never be copyrighted. Other than that, misuse it anyhow you wish.

###  Health Score

22

—

LowBetter than 21% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity4

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity50

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~0 days

Total

2

Last Release

3291d ago

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/44860194?v=4)[vgait](/maintainers/vgait)[@vgait](https://github.com/vgait)

---

Top Contributors

[![maxpeed](https://avatars.githubusercontent.com/u/9416727?v=4)](https://github.com/maxpeed "maxpeed (27 commits)")

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/vgait-vgadatabase/health.svg)

```
[![Health](https://phpackages.com/badges/vgait-vgadatabase/health.svg)](https://phpackages.com/packages/vgait-vgadatabase)
```

###  Alternatives

[jdorn/sql-formatter

a PHP SQL highlighting library

3.9k116.5M113](/packages/jdorn-sql-formatter)[propel/propel1

Propel is an open-source Object-Relational Mapping (ORM) for PHP5.

8351.6M87](/packages/propel-propel1)[pgvector/pgvector

pgvector support for PHP

198628.3k10](/packages/pgvector-pgvector)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
