PHPackages                             hotelmah/mysqli-wrapper - 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. hotelmah/mysqli-wrapper

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

hotelmah/mysqli-wrapper
=======================

This MySQLi wrapper base class provides properties for Connection and Query Error Messages and ResultSet Properties and Methods to navigate a ResultSet. Connection and Server properties are also provided, basically all of the available features the extension provides.

v1.0.2(1y ago)0151GPL-3.0-onlyPHPPHP &gt;=7.0.0

Since Dec 21Pushed 1y ago1 watchersCompare

[ Source](https://github.com/hotelmah/mysqli-wrapper)[ Packagist](https://packagist.org/packages/hotelmah/mysqli-wrapper)[ Docs](https://github.com/hotelmah/mysqli-wrapper)[ RSS](/packages/hotelmah-mysqli-wrapper/feed)WikiDiscussions main Synced 1mo ago

READMEChangelog (1)DependenciesVersions (3)Used By (1)

About
-----

[](#about)

This library/package is a wrapper class of the PHP MySQLi 8.0 database extension. This class provides connection and query error message and number properties. This class can navigate a ResultSet and provides useful properties of the ResultSet like number of rows.

The base class is generic and not specific to any particular project or library. The extended class in this library is used by the MySQL Table Editor (MTE) project referenced [here](https://github.com/hotelmah/mysql-table-editor).

If you would like me to write an extended class for your particular needs, please open an issue or discussion.

Features
--------

[](#features)

- 3x Connection properties: connectionCheckIfGood(), connectionGetErrorNumber(), connectionGetErrorMessage().
- 9x Query related properties: queryCheckIfGood(), queryInfo(), queryGetErrorNumber(), queryGetErrorMessage(), queryGetErrorListCount(), queryGetErrorListMessages(), queryGetInsUpdAutoGenID(), queryGetAffectedRows(), queryGetWarningCount().
- 2x ResultSet properties: resultSetFetchNumFields(), resultSetFetchNumRows().
- 4x ResultSet methods: resultSetFetchAllRows(), resultSetFetchNextRow(), resultSetFetchAllFields(), resultSetClose().
- 7x Connection/Server properties.

Setup (Important)
-----------------

[](#setup-important)

- Please edit the config.server.constants.php file in the src folder manually. The database connection properties are read from this file.
- There is no automated setup for this.

Test File
---------

[](#test-file)

- A test file is not included.
- This is because there is no test database server and sample database to connect to.

In your Script
--------------

[](#in-your-script)

- Add the following in your script:

`require_once('vendor/autoload.php');`

`use MySQLi\ClsDataBaseWrapperBase;`

Preferablly, you may want to extend the base for your particular needs. The database config file is in the src folder and is read by the base class.

Installation - Composer
-----------------------

[](#installation---composer)

- run this command in your project root:

`composer require hotelmah/mysqli-wrapper`

- There is no need to manually create/update a composer.json file in your project root since this command does it automatically.
- The package is listed on Packagist, but is hosted on GitHub where the source is pulled from.
- See setup section above.

Installation - Manual
---------------------

[](#installation---manual)

- Copy the src directory contents to an appropriately named directory like includes/ in your LAMP web hosting provider.
- Refer to the 'In your Script' heading above and/or test file.

Feedback
--------

[](#feedback)

- Forks and Pull Requests are welcomed.
- Suggestions and comments for improvement are requested.
- Thank you for reading!

License
-------

[](#license)

- GNU GENERAL PUBLIC LICENSE, Version 3.

###  Health Score

24

—

LowBetter than 32% of packages

Maintenance42

Moderate activity, may be stable

Popularity6

Limited adoption so far

Community9

Small or concentrated contributor base

Maturity34

Early-stage or recently created project

 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

504d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/680e03dee8e2034db2678e5f8da8ca412074d13741637f5a8b40d4be1c118e1f?d=identicon)[hotelmah](/maintainers/hotelmah)

---

Top Contributors

[![hotelmah](https://avatars.githubusercontent.com/u/189757542?v=4)](https://github.com/hotelmah "hotelmah (2 commits)")

---

Tags

databasemysqliphprecordsetwrapperphpdatabasewrappermysqli

### Embed Badge

![Health badge](/badges/hotelmah-mysqli-wrapper/health.svg)

```
[![Health](https://phpackages.com/badges/hotelmah-mysqli-wrapper/health.svg)](https://phpackages.com/packages/hotelmah-mysqli-wrapper)
```

###  Alternatives

[stefangabos/zebra_database

An advanced, compact and lightweight MySQL database wrapper library, built around PHP's MySQLi extension.

11812.0k](/packages/stefangabos-zebra-database)

PHPackages © 2026

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