--union并操作
select e.employee_id,e.last_name from hr.employees e
where e.last_name like ‘C%‘
union
select e.employee_id,e.last_name from hr.employees e
where e.last_name like ‘S%‘;
--等价于
select e.employee_id,e.last_name from hr.employees e
where e.last_name like ‘C%‘or e.last_name like ‘S%‘;
-- intersect交集操作
select e.employee_id,e.last_name from hr.employees e
where e.last_name like ‘C%‘or e.last_name like ‘S%‘
intersect
select e.employee_id,e.last_name from hr.employees e
where e.last_name like ‘S%‘or e.last_name like ‘T%‘;
--等价于
select e.employee_id,e.last_name from hr.employees e
where e.last_name like ‘S%‘;
--minus差操作
select e.employee_id,e.last_name from hr.employees e
where e.last_name like ‘C%‘or e.last_name like ‘S%‘
minus
select e.employee_id,e.last_name from hr.employees e
where e.last_name like ‘S%‘or e.last_name like ‘T%‘;
--等价于
select e.employee_id,e.last_name from hr.employees e
where e.last_name like ‘C%‘;
博客:
http://www.cnblogs.com/ssslinppp
http://blog.sina.com.cn/spstudy
淘宝-代做毕设:
http://shop110473970.taobao.com/?spm=a230r.7195193.1997079397.42.AvYpGW
http://shop125186102.taobao.com/?spm=a1z10.1-c.0.0.SsuajD