Aquí va la sintaxis de PIVOT
SELECT Name,[1] as Animal, [2] as Color
FROM
(SELECT Name,Id,Value
FROM Table) AS SourceTable
PIVOT
(
MIN(Value)
FOR Id IN ([1], [2])
) AS PivotTable;
Aquí va la sintaxis de PIVOT
SELECT Name,[1] as Animal, [2] as Color
FROM
(SELECT Name,Id,Value
FROM Table) AS SourceTable
PIVOT
(
MIN(Value)
FOR Id IN ([1], [2])
) AS PivotTable;