$ 0 0 try, select id, max(case when name ='a' then value else null end) as A, max(case when name ='b' then value else null end) as B, .. from table group by 1 Regards Gerardo
try,
select id,
max(case when name ='a' then value else null end) as A,
max(case when name ='b' then value else null end) as B,
..
from table
group by 1
Regards
Gerardo