Quantcast
Channel: Transact-SQL forum
Viewing all articles
Browse latest Browse all 23857

Simple way of changing from rows to columns?

$
0
0

I would like to use this result with an ssrs chart, but apparently, it would be easier for the chart to 'display' this if it were column-wise instead of rows.

Is there a relatively easy way of 'transforming' the data so that every row is a week? So, for example, one row would be (Week 1, KPI1, NY, 1, FL, 2, TX, 3, etc).

Thanks.

Rank     KPI        WeekNum    State
1          KPI1          1               NY
2          KPI1          1               FL
3          KPI1          1               TX
4          KPI1          1               AR
5          KPI1          1               NJ
13         KPI1          1               CA
1          KPI1          2               NY
2          KPI1          2               FL
3          KPI1          2               GA
4          KPI1          2               OK
5          KPI1          2               NJ
14         KPI1          2               CA


VM


Viewing all articles
Browse latest Browse all 23857

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>