SQLSERVER数据集合的交、并、差集运算(intersect,union,except)
摘要:
SQLServer中通过intersect,union,except和三个关键字对应交、并、差三种集合运算。 他们的对应关系可以参考下面图示 测试示例: 构造A,B两个数据集 查询示例: 1 Union 取合集并过滤重复数据 2 Union all 取合集不过滤重复数据 3 Intersect 取交 阅读全文
posted @ 2018-05-29 00:11 癫狂编程 阅读(1352) 评论(0) 推荐(0) 编辑