mysql 查询——逻辑查询

 1 --去重查询 distinct
 2 select distinct gander from student;
 3 
 4 --逻辑查询
 5    and or not
 6    --查询18-28之间的数据
 7    select *from student age>18 and age<28;
 8    --查询age大于18的女性
 9    select *from student age>18 and name="lady";
10    --多条件查询
11    select * from student where age>10 and gender="man" and high>150;
12 
13    --查询不是age大于18的女性  not
14    select *from student not (age>18 and name="lady");

 

posted @ 2019-07-24 01:22  jum_blog  阅读(576)  评论(0编辑  收藏  举报

载入天数...载入时分秒...