An Action folder (library)
1. Increase
Create Database db1 charset UTF8;
2. By deleting
Drop database db1;
3. Change
ALTER DATABASE DB1 CharSet GBK;
4. Check
# View the database you are currently creating show CREATE Database db1;# view all databases show databases;
Second, table operation
Use DB1; #切换文件夹
Select Database (); #查看当前所在文件夹
1. Increase
int Char);
2. Check
#查看当前的这张t1表show CREATE table t1;# See all Tables show tables;# see table details desc t1;
3. Change
Char (6Char(7);
4. By deleting
# Delete tables drop table T1;
Three operation file contents (record)
1. Increase
# Insert a piece of data that specifies id,name data Leileiinsert T1 (id,name) VALUES (1,"mjj01"), ( 2,"mjj02"), (3,"mjj03");
2. Check
Select from db1.t1; Select from db1.t1; Select from
3. Change
set name=' Zhangsan'set name='Alex' where id=2;
4. By deleting
from fromwhere id=2;
MySQL Basic statement