摘要:
1.权限管理:root 创建用户: create user chen identified by '123456 修改密码: update mysql.user set authentication_string='123456' where Host='localhost' and User='r 阅读全文
摘要:
1.分页 limit offset 和排序 order by desc 降序 asc 升序 select a.1,2,3,4 from a inner join b on a.1=b.1 inner join c on c.2=b.2 where 3='xxx' order by 4 desc (a 阅读全文
摘要:
1.聚合函数: select * from user where concat(use,addr) like "%"#{name}"%"; 1.count() count(字段)忽略所有null count(*) 不忽略null count(1) 不忽略null 2.sum() 3.avg() 4. 阅读全文
摘要:
1.联表查询 必须多表要有相同的列 (多表查询) select a.name,sex,password from 表1 as a inner join 表2 as b on a.name=b.name; select a.name ,password, sex from 表1 as a left j 阅读全文
摘要:
1.where 条件 1.and && or || Not ! where Nnot Id='001'; 2. is NULL > id is null is null ' '; is not NULL > id is not null between and > id between a and 阅读全文
摘要:
1.DQL select 指定查询字段: select * from 表名; select * from 表名 where username='xxxx'; select * from 表名 where username is NULL; select username as ‘用户名’,passw 阅读全文