标签:actions 它的 nec 变量 character dba rip 完整性 alter
MySQL数据库以及表的管理
作者:尹正杰
版权声明:原创作品,谢绝转载!否则将追究法律责任。
1 mysql> help create database 2 Name: ‘CREATE DATABASE‘ 3 Description: 4 Syntax: 5 CREATE {DATABASE | SCHEMA} [IF NOT EXISTS] db_name 6 [create_specification] ... 7 8 create_specification: 9 [DEFAULT] CHARACTER SET [=] charset_name #设置字符集 10 | [DEFAULT] COLLATE [=] collation_name #设置排序方式 11 12 CREATE DATABASE creates a database with the given name. To use this 13 statement, you need the CREATE privilege for the database. CREATE 14 SCHEMA is a synonym for CREATE DATABASE. 15 16 URL: http://dev.mysql.com/doc/refman/5.1/en/create-database.html 17 18 19 mysql>
1 mysql> show databases; 2 +--------------------+ 3 | Database | 4 +--------------------+ 5 | information_schema | 6 | mysql | 7 | test | 8 +--------------------+ 9 3 rows in set (0.00 sec) 10 11 mysql> 12 mysql> create database yinzhengjie; 13 Query OK, 1 row affected (0.01 sec) 14 15 mysql> show databases; 16 +--------------------+ 17 | Database | 18 +--------------------+ 19 | information_schema | 20 | mysql | 21 | test | 22 | yinzhengjie | 23 +--------------------+ 24 4 rows in set (0.00 sec) 25 26 mysql>
1 mysql> show databases; 2 +--------------------+ 3 | Database | 4 +--------------------+ 5 | information_schema | 6 | mysql | 7 | test | 8 | yinzhengjie | 9 +--------------------+ 10 4 rows in set (0.00 sec) 11 12 mysql> create database if not exists yinzhengjie; 13 Query OK, 1 row affected, 1 warning (0.00 sec) 14 15 mysql> show databases; 16 +--------------------+ 17 | Database | 18 +--------------------+ 19 | information_schema | 20 | mysql | 21 | test | 22 | yinzhengjie | 23 +--------------------+ 24 4 rows in set (0.00 sec) 25 26 mysql>
标签:actions 它的 nec 变量 character dba rip 完整性 alter
原文地址:http://www.cnblogs.com/yinzhengjie/p/7853552.html