PHPackages                             emalherbi/mymysql - 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. emalherbi/mymysql

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

emalherbi/mymysql
=================

My Mysql | PDO

2.0.2(1y ago)0113MITPHPPHP &gt;= 5.0.0

Since Apr 14Pushed 1y ago1 watchersCompare

[ Source](https://github.com/emalherbi/MyMysql)[ Packagist](https://packagist.org/packages/emalherbi/mymysql)[ Docs](https://github.com/emalherbi/MyMysql)[ RSS](/packages/emalherbi-mymysql/feed)WikiDiscussions main Synced today

READMEChangelog (1)DependenciesVersions (2)Used By (0)

MyMysql
=======

[](#mymysql)

My Mysql | PDO

Install
=======

[](#install)

```
composer require emalherbi/mymysql

```

Usage
=====

[](#usage)

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

try {
    $mysql = new MyMysql\MyMysql(array(
        'DB_LOG' => true,
        'DB_HOST' => '192.168.1.100',
        'DB_NAME' => 'DATABASE',
        'DB_USER' => 'USERNAME',
        'DB_PASS' => 'PASSWORD',
    ), realpath(dirname(__FILE__)));

    /* fetch */

    $result = $mysql->fetchRow('CLIENTS', array('ID_CLIENTS' => '2'), 'ORDER BY ID_CLIENTS');
    echo '';
    echo print_r($result);
    echo '';

    $result = $mysql->fetchRow2('SELECT * FROM CLIENTS');
    echo '';
    echo print_r($result);
    echo '';

    $result = $mysql->fetchAll('CLIENTS', array('ID_CLIENTS' => '2'), 'ORDER BY ID_CLIENTS');
    echo '';
    echo print_r($result);
    echo '';

    $result = $mysql->fetchAll2('SELECT * FROM CLIENTS LIMIT 2');
    echo '';
    echo print_r($result);
    echo '';

    /* insert */

    $item = new stdClass();
    $item->ID_BOARD = 0;
    $item->CODE = 999;
    $item->DESCRIPTION = 'TEST';
    $item->ACTIVE = 1;

    $result = $mysql->insert('BOARD', $item);
    echo '';
    echo print_r($result);
    echo '';

    /* update */

    $ID_BOARD = 530;
    $item = new stdClass();
    $item->CODE = 999;
    $item->DESCRIPTION = 'TEST';
    $item->ACTIVE = 1;

    $result = $mysql->update('BOARD', $item, array('ID_BOARD' => $ID_BOARD), $ID_BOARD);
    echo '';
    echo print_r($result);
    echo '';

    /* delete */

    $ID_BOARD = 531;
    $result = $mysql->delete('BOARD', array('ID_BOARD' => $ID_BOARD));
    echo '';
    echo print_r($result);
    echo '';

    /* execute */

    $sql = " INSERT INTO BOARD(CODE, DESCRIPTION) VALUES (888, 'TEST') ";
    $result = $mysql->execute($sql);
    echo '';
    echo print_r($result);
    echo '';

    echo 'Success...';
} catch (Exception $e) {
    die(print_r($e->getMessage().'-'.$mysql->getError()));
}
```

###  Health Score

25

—

LowBetter than 37% of packages

Maintenance47

Moderate activity, may be stable

Popularity10

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity32

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

Unknown

Total

1

Last Release

393d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/78209cde44e95321c282224a567bb219aa794e78ce00db2e13be102108420d56?d=identicon)[emalherbi](/maintainers/emalherbi)

---

Top Contributors

[![emalherbi](https://avatars.githubusercontent.com/u/94532309?v=4)](https://github.com/emalherbi "emalherbi (3 commits)")

### Embed Badge

![Health badge](/badges/emalherbi-mymysql/health.svg)

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

###  Alternatives

[doctrine/orm

Object-Relational-Mapper for PHP

10.2k285.3M6.2k](/packages/doctrine-orm)[jdorn/sql-formatter

a PHP SQL highlighting library

3.9k115.1M102](/packages/jdorn-sql-formatter)[illuminate/database

The Illuminate Database package.

2.8k52.4M9.4k](/packages/illuminate-database)[mongodb/mongodb

MongoDB driver library

1.6k64.0M546](/packages/mongodb-mongodb)[ramsey/uuid-doctrine

Use ramsey/uuid as a Doctrine field type.

90340.3M211](/packages/ramsey-uuid-doctrine)[reliese/laravel

Reliese Components for Laravel Framework code generation.

1.7k3.4M16](/packages/reliese-laravel)

PHPackages © 2026

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