日期:2014-05-17  浏览次数:20886 次

纵向排列如何改成横向的?????????
纵向排列如何改成横向的?????????
 oracle的sql语句如下:
 select distinct
  zla.authorized_person  
  from sdcd.zdeco_head_all h,sdcd.zdeco_line_all zla
 where h.zdeco_head_id=zla.zdeco_head_id
 and h.zdeco_head_number='2012049'
 运行结果:
authorized_person
张三
李四
王五

但是我想要的是下面的效果:

authorized_person
张三,李四,王五

或者
authorized_person
张三 李四 王五

请问这条SQL语句应该怎么修改?????????


------解决方案--------------------
不要发重复贴