日期:2014-05-16  浏览次数:20423 次

使用WMSYS.WM_CONCAT函数实现行列转换

转自:?http://blog.csdn.net/zhpsam109/article/details/1917011

?

SQL> select version from v$instance;
?
VERSION
-----------------
10.2.0.1.0
?
SQL>?
SQL> create table IDTABLE
? 2? (
? 3??? id? number,
? 4??? val varchar2(20)
? 5? )
? 6? ;
?
Table created
?
SQL>?
SQL> insert into IDTABLE (ID, VAL)
? 2? values (10, 'abc');
?
1 row inserted