oracle 行转列 使用PIVOT关键字
select * from (SELECT STOP_ID,POSITION,INSTANT,SET_VALUE from table1)pivot(
min(INSTANT) I,min(SET_VALUE) V FOR POSITION IN(
1 AS HT1,
2 AS HT2,
3 AS HT3,
4 AS HT4,
5 AS HT5,
6 AS HT1,
7 AS HT2
)
)