ride/cli-database
最新稳定版本:1.0.1
Composer 安装命令:
composer require ride/cli-database
包简介
Database commands for the Ride CLI
README 文档
README
This module adds various database commands to the Ride CLI.
Commands
database
This command shows an overview of the database connections in the manager.
Syntax: database
Alias: db
database convert utf8
This command converts all tables from the provided database connection to UTF-8.
Syntax: database convert utf8 <name>
<name>: Name of the connection
Alias: dbutf8
database create
This command creates the database on the server of the connection if it does not exist.
Syntax: database create [<name> [<charset> [<collation>]]]
<name>: Name of the connection<charset>: Default charset for the database (default utf8)<collation>: Default collation for the database (default utf8_general_ci)
Alias: dbc
database default
This command gets or sets the name of the default database connection.
Syntax: database default <name>
<name>: Name of the connection
Alias: dbdef
database drop
This command drops the database on the server of the connection if it exists.
Syntax: database drop <name>
<name>: Name of the connection
Alias: dbdr
database add
This command registers a database connection in the manager.
Syntax: database add <name> <dsn>
<name>: Name for the connection<dsn>: DSN of the connection (protocol://username:password@host:port/database)
Alias: dba
database status
This command gets the status of a connection.
Syntax: database status [<name>]
<name>: Name of the connection
Alias: dbs
database delete
This command unregisters a database connection from the manager.
Syntax: database delete <name>
<name>: Name for the connection
Alias: dbd
database driver
This command shows an overview of the available database drivers.
Syntax: database driver
database query
This command executes a SQL query on the default database connection.
Syntax: database query [--connection] [<sql>]
--connection: Name of the connection to use<sql>: The SQL script to execute
Alias: dbq or query
Related Modules
Installation
You can use Composer to install this application.
composer require ride/cli-database
统计信息
- 总下载量: 4.28k
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 0
- 点击次数: 0
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2014-02-21