 <p>can you format your data in question. I am not sure whether I get youe point?</p> <pre><code> CREATE TABLE #tt([name] VARCHAR(10),[date] DATE,skill INT,seconds INT, calls int ) INSERT INTO #tt SELECT 'bob','9/2/2016',706,12771,56 UNION all SELECT 'bob','9/2/2016',707,4061,16 UNION all SELECT 'bob','9/2/2016',708,2577,15 UNION all SELECT 'bob','9/2/2016',709,2156,6 SELECT * FROM ( SELECT t.name,t.date,c.* FROM #tt AS t CROSS APPLY(VALUES(LTRIM(t.skill)+'sec',t.seconds),(LTRIM(t.skill)+'calls',t.seconds)) c(t,v) ) AS A PIVOT(MAX(v) FOR t IN ([706sec],[706calls],[707sec],[707calls],[708sec],[708calls],[709sec],[709calls])) p </code></pre> <pre> name date 706sec 706calls 707sec 707calls 708sec 708calls 709sec 709calls ---------- ---------- ----------- ----------- ----------- ----------- ----------- ----------- ----------- ----------- bob 2016-09-02 12771 12771 4061 4061 2577 2577 2156 2156 </pre> <p>if the count of skill is not fix, you can use dynamic script：</p> <pre><code> DECLARE @col VARCHAR(max),@sql VARCHAR(max) SELECT @col=ISNULL(@col+',[','[')+LTRIM(skill)+'sec],['+LTRIM(skill)+'calls]' FROM #tt GROUP BY skill SET @sql=' SELECT * FROM ( SELECT t.name,t.date,c.* FROM #tt AS t CROSS APPLY(VALUES(LTRIM(t.skill)+''sec'',t.seconds),(LTRIM(t.skill)+''calls'',t.seconds)) c(t,v) ) AS A PIVOT(MAX(v) FOR t IN ('+@col+')) p' EXEC (@sql) </code></pre>