techone/database 问题修复 & 功能扩展

解决BUG、新增功能、兼容多环境部署,快速响应你的开发需求

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

techone/database

最新稳定版本:v2.0.0

Composer 安装命令:

composer require techone/database

包简介

PDO database library

README 文档

README

PHPUnit Coverage Status Latest Stable Version Total Downloads License

PDO database library for PHP.

the current supported databases are:

type database
mysql MySQL
pgsql PostgreSQL
sqlite SQLite
sqlsrv SqlServer

Installation

Use Composer

composer require leeqvip/database

Usage

require_once './vendor/autoload.php';

use Leeqvip\Database\Manager;

$config = [
    'type'     => 'mysql', // mysql,pgsql,sqlite,sqlsrv
    'hostname' => '127.0.0.1',
    'database' => 'test',
    'username' => 'root',
    'password' => 'abc-123',
    'hostport' => '3306',
];

$manager = new Manager($config);
$connection = $manager->getConnection();

$connection->query('SELECT * FROM `users` WHERE `id` = :id', ['id' => 1]);

$connection->execute('UPDATE `users` SET `name` = "joker" where `id` = :id', ['id' => 1]);

License

This project is licensed under the Apache 2.0 license.

统计信息

  • 总下载量: 52.19k
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 5
  • 点击次数: 1
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 5
  • Watchers: 2
  • Forks: 3
  • 开发语言: PHP

其他信息

  • 授权协议: Apache-2.0
  • 更新时间: 2018-10-16