热线电话:13121318867

登录
2018-11-27 阅读量: 863
联合查询

union: 用于合并两个或多个 SELECT 语句的结果集,并消去表中任何重复行。

例: 用union合并t1与t2表

select t1.* from t1

union

select t2.* from t2;

union all:用于合并两个或多个 SELECT 语句的结果集,保留重复行。

例: 用union all合并t1与t2表

select t1.* from t1 union all

select t2.* from t2;

�����޾�)

0.0000
4
关注作者
收藏
评论(0)

发表评论

暂无数据
推荐帖子