查询语句
select * from 表名 查询所有字段
select account from 表名 查询account字段
select account,passowrd from 表名 查询account和passowrd字段
删除语句
delete from 表名 where account="110" 从表中删除account为110的记录
插入语句
insert into users (account,password,age) values ("110","506666","15")
修改语句
update users set account='120',age=50 where Id=2
where子语句,条件查询
select * from 表名 where Id=9
select * from users where account ="李云迪"
指定范围
select name,age from 表名 where age>=25
同时满足两个条件
select name,age from 表名 where phone='1506065500' and age=25
满足任意一个条件
select name,age from 表名 where phone='15060655' or age=25
like子语句, 模糊查询
'%a' //以a结尾的数据
'a%' //以a开头的数据
'%a%' //含有a的数据
'_a_' //三位且中间字母是a的
'_a' //两位且结尾字母是a的
'a_' //两位且开头字母是a的
查询name字段以李开头的记录
select * from 表名 where name like '李%'
limit子语句(用于分页查询)
select * from 表名 limit 0,3 从第几条开始 查询几条内容