select distinct id,(select content from zb1 b where b.id=a.id and b.xh=0),(select content from zb1 b where b.id=a.id and b.xh=1),
(select content from zb1 b where b.id=a.id and b.xh=2),(select content from zb1 b where b.id=a.id and b.xh=3) from zb1 a ;
(select content from zb1 b where b.id=a.id and b.xh=2),(select content from zb1 b where b.id=a.id and b.xh=3) from zb1 a ;
select id,max(decode(xh,0,content,null)),max(decode(xh,1,content,null)),max(decode(xh,2,content,null))
from temp group by id