题解 | #查询职位城市在北京或者职位工资高于#
查询职位城市在北京或者职位工资高于100000的job_id和company_id,结果不去重
https://www.nowcoder.com/practice/5eec83ed40074b7dadfcff16cecfcdcb
select job_id,company_id from job_info where job_city='北京' union all select job_id,company_id from job_info where salary>100000;;
这题的关键在于合并不去重,一开始我没有看到,只是使用or进行判断,结果返回的是去重的结果,这个题需要使用union all 进行全外连接查询