当前位置: 代码迷 >> Oracle开发 >> 查询结果拼接
  详细解决方案

查询结果拼接

热度:101   发布时间:2016-04-24 06:38:19.0
查询结果拼凑
比如这样查询语句
1,select name ,age from T where ...

亨克 18
扎思 20

2,select ‘拉菲’,23 from T

拉菲 23

这2个语句怎么弄,才能打印出

亨克 18
扎思 20
拉菲 23
------解决方案--------------------
union all 一下
------解决方案--------------------
select name ,age from T where ...
union all
select ‘拉菲’,23 from dual
  相关解决方案