Skip to content

yiisoft/db-mysql

 
 

Repository files navigation

Yii DataBase MySQL Extension


Yii Database MySQL Extension is a database extension for the Yii Framework that allows developers to access and interact with MySQL and MariaDb databases. It provides a set of classes and methods for connecting to a MySQL and MariaDb database, executing SQL queries, and managing data within the database. The extension is designed to be easy to use and integrate into Yii-based applications, and supports a wide range of MySQL, MariaDb features and functions. It also includes support for transactions, database schema management, and error handling.

It is used in Yii Framework but can be used separately.

Latest Stable Version Total Downloads rector codecov StyleCI type-coverage

Support version

PHP Mysql/MariaDb CI-Actions
8.0-8.2 5.7-8.0/10.4-10.10 build ansi-mode Mutation testing badge static analysis

Installation

The package could be installed via composer:

composer require yiisoft/db-mysql

Usage

For config connection to Mysql, MariaDb database check Connecting MySQL/MariaDb.

Check the documentation docs to learn about usage.

Testing

Unit testing

The package is tested with PHPUnit. To run tests:

./vendor/bin/phpunit

Mutation testing

The package tests are checked with Infection mutation framework. To run it:

./vendor/bin/infection

Static analysis

The code is statically analyzed with Psalm. To run static analysis:

./vendor/bin/psalm

Rector

Use Rector to make codebase follow some specific rules or use either newest or any specific version of PHP:

./vendor/bin/rector

Composer require checker

This package uses composer-require-checker to check if all dependencies are correctly defined in composer.json.

To run the checker, execute the following command:

./vendor/bin/composer-require-checker

Support the project

Open Collective

Follow updates

Official website Twitter Telegram Facebook Slack

License

The Yii DataBase MySQL Extension is free software. It is released under the terms of the BSD License. Please see LICENSE for more information.

Maintained by Yii Software.

Sponsor this project

  •  

Contributors 289

Languages