shencongcong/mysql
Composer 安装命令:
composer require shencongcong/mysql
包简介
a esay method operating mysql
README 文档
README
a esay method operating mysql.
环境需求
- PHP >= 5.6
Installing
$ composer require shencongcong/mysql -vvv
Usage
use Shencongcong\Mysql\Mysql $config = [ 'host' => '10.0.0.180', 'database' => 'db', 'user' => 'root', 'password' => 'root', 'port' => '3306', ], $db = Mysql::getDbInstance($config); ### 增 $db->table('users')->insert(['user'=>'xxx','pwd'=>'xxx']); ### 删 $db->table('users')->where(['user'=>'xxx'])->delete(); ### 改 $db->table('users')->where('user'=>'xxx')->update(['name'=>'xxx']); ### 查一条 $db->table('users')->where(['user'=>'xxx'])->find(); ### 查全部 $db->table('users')->where(['user'=>'xxx'])->select(); ### 字段查找 $db->table('users')->field('user')->where(['user'=>'xxx'])->select(); ### 排序 $db->table('users')->where(['user'=>'xxx'])->order('id desc')->select(); ### join $db->table('users')->join('user_info on user_info.user_id=user.id')->select(); ### 执行原生sql $db->table('users')->query('select * from users');
Contributing
You can contribute in one of three ways:
- File bug reports using the issue tracker.
- Answer questions or fix bugs on the issue tracker.
- Contribute new features or update the wiki.
The code contribution process is not very formal. You just need to make sure that you follow the PSR-0, PSR-1, and PSR-2 coding guidelines. Any new code contributions must be accompanied by unit tests where applicable.
License
MIT
shencongcong/mysql 适用场景与选型建议
shencongcong/mysql 是一款 基于 PHP 开发的 Composer 扩展包,目前已累计 311 次下载、GitHub Stars 达 3, 最近一次更新时间为 2019 年 07 月 10 日, 在 PHP 生态内属于活跃度较高的组件。
我们在过去多个企业项目中使用过 shencongcong/mysql 或与其功能相近的方案,如果你在选型或落地过程中遇到问题,例如 版本兼容、二次改造、私有化封装、与内部系统对接、生产 BUG 排查,欢迎联系我们协助评估。
基于 shencongcong/mysql 在你已有业务上做功能扩展、字段裁剪、UI 适配、与内部账号 / 权限 / 日志系统的深度对接。
线上偶发问题、内存泄漏、慢查询、并发异常等排查修复;针对高流量场景做缓存、队列、索引层面的调优。
承接完整的项目从需求 → 设计 → 开发 → 上线 → 长期运维;也可按月提供技术保姆服务。
统计信息
- 总下载量: 311
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 3
- 点击次数: 6
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2019-07-10