最新下载
热门教程
- 1
- 2
- 3
- 4
- 5
- 6
- 7
- 8
- 9
- 10
mysql 创建数据库,删除数据库实例
时间:2022-11-14 23:37:43 编辑:袖梨 来源:一聚教程网
mysql教程 创建数据库教程,删除数据库实例
CREATE DATABASE
mysql>
mysql>
mysql> CREATE DATABASE myDatabase;
Query OK, 1 row affected (0.03 sec)
mysql>
mysql> drop database myDatabase;
Query OK, 0 rows affected (0.01 sec)
mysql>
Under Unix, database and table names are case sensitive.
Under Windows, this restriction does not apply
mysql>
用use改变当前表
mysql>
mysql>
mysql> CREATE DATABASE myDatabase;
Query OK, 1 row affected (0.02 sec)
mysql> USE myDatabase; -- Select it manually
Database changed
mysql> drop database myDatabase;
Query OK, 0 rows affected (0.00 sec)
mysql>
mysql>
缩合上面的实例
mysql>
mysql> CREATE DATABASE myDatabase DEFAULT CHARACTER SET latin2 COLLATE latin2_czech_ci;
Query OK, 1 row affected (0.02 sec)
mysql>
mysql>
mysql>
mysql> USE myDatabase;
Database changed
mysql>
mysql> CREATE TABLE myTable
-> (
-> c1 CHAR(10)
-> );
Query OK, 0 rows affected (0.03 sec)
mysql>
mysql> drop table myTable;
Query OK, 0 rows affected (0.00 sec)
mysql>
mysql> drop database myDatabase;
Query OK, 0 rows affected (0.00 sec)
mysql>
mysql> use test;
Database changed
相关文章
- 人们熟悉的寄居蟹属于以下哪种分类 神奇海洋11月21日答案 11-21
- 第五人格11.22共研服有什么更新 11月22日共研服更新内容介绍 11-21
- 原神恰斯卡怎么培养 11-21
- 无期迷途四星装束是谁 11-21
- 王者荣耀帝丹高中校服怎么获得 11-21
- 光遇姆明季后续版本怎么玩 11-21