问题:出现什么问题,搜哪里
卸载问题:5.x — 注册表
编码 — 选择utf8
latin -utf8
如果出不是内部命令情况下,path中的路径用全路径
mysql -u root -p 或者是mysql -u root -p root
quit 或 exit
mysql -V #未登录使用
mysql --version #未登录使用
select version() #登录使用
show status like ‘threads_connected%’;
show databases;
show schemas;
select database();
create database tyut charset=utf8/utf8mb4;
alter database tyut charset =utf8mb4;
drop database tyut;
use tyut;
create table student(
student_id bigint(10) not null,
name varchar(20) default null,
state char(1) default null,
primary key(student_id)
);
show tables;
desc student;
show create table student\G;
rename table student
drop table student;
操作字段的关键字 alter
alter table student add(class varchar(20));
alter table student change 原字段名 新字段名 类型;
alter table student change weight w int(10);
alter table student modify weight double;
alter table student drop a3;
select student_id ,name from student;
select name from (select student_id ,name from student);
insert into student(id,name,state) values(1,“wang”,“1”);
insert into student values(2,“wang”,“1”);
insert into student values(3,“zhang”,“0”);
insert into student values(4,“li”,“1”);
insert into student values(5,“meng”,“1”);
update student set name=“Li” where student_id =1;
delete from student where student_id =1;
delete from student;
delete from student where student_id =1;