select to_char(a.name) name_a from a union select to_char(b.name) name_b from b
强行转换2个字段的类型为char型,在查询的结果集中就可以正常显示这2个结果了
另:
union 去掉重复
union all 不去掉重复
select to_char(a.name) name_a from a union select to_char(b.name) name_b from b
强行转换2个字段的类型为char型,在查询的结果集中就可以正常显示这2个结果了
另:
union 去掉重复
union all 不去掉重复