------解决方案-------------------- select a,b from test union select a,b from test where c=1
------解决方案--------------------
SQL code
select a,b from test
union--去掉上下两个语句重复的数据行
select a,b from test where c=1
select a,b from test
union all--不去掉上下两个语句重复的数据行,保留两语句的所有结果航
select a,b from test where c=1
------解决方案--------------------