Forum Discussion
Best practices for pivoting dimension
- 9 years ago
Hi s15,
Yes, we need one table and two measures in this scenario. I believe there are also other ways.
I sampled a table from yours. And the two measures are:
Sales2013 = CALCULATE ( SUM ( 'Financials'[Sales] ), 'Financials'[Year] = 2013 )
Sales2014 = CALCULATE ( SUM ( Financials[Sales] ), 'Financials'[Year] = 2014 )
Best Regards!
Dale
Thank you very much for your support v-jiascu-msft
Measure is really useful and it reduces my effort to duplicate my table. However, if I want to add 2013 and 2014 to my slicer chart, measure does not help right? In this case I would still need to duplicate my table and remove unnecessary column.
Hi s15,
Measure can't be added in the slicer visual by now. Do you mean it as the picture shows? Or you could post it here. Maybe we could find out a workaround.
BTW, I am going to update the two measures, which will be more accurate.
Sales2013 =
CALCULATE (
SUM ( 'Financials'[Sales] ),
FILTER ( 'Financials', 'Financials'[Year] = 2013 )
)Sales2014 =
CALCULATE (
SUM ( Financials[Sales] ),
FILTER ( 'Financials', 'Financials'[Year] = 2014 )
)
Best Regards!
Dale
- s159 years ago
Helper III
That's correct. I want to extract two value of year (2013 and 2014) from the Years to add to slicer chart. That's one of the reason why the question came out.
Thank you.