22 Jun 2018 by Maciej Los
You can't just pivot data, you need to unpivot it first. Check this: DECLARE @tmp TABLE (ProductType NVARCHAR(30), YTD_SPD DECIMAL(20,8), Var_SPD DECIMAL(20,8), Per_SPD DECIMAL(20,8)) INSERT INTO @tmp (ProductType, YTD_SPD, Var_SPD, Per_SPD) VALUES('OutboundNON DOC', 2448.029903, 244.0843848,...