Forum Discussion
mvmania
9 years agoRegular Visitor
Slicer by Column
Hi, I am very new to use Power BI. Thank you in advance for your answers. I developed a table like below Project Budget 2016 Budget 2017 Project1 ...
- 9 years agoGo to the query editor, highlight both 2016 and 2017 columns (shift + mouse click), then click "unpivot columns" in the Transform tab. This will give you 2 columns: budget and year. Notice how your rows for project number have doubled, with a row for 2016 and a row for 2017. Now you can create a chart with the budget field for the value, and add a slicer with budget year as field that will filter the chart.
dkay84_PowerBI
9 years agoMicrosoft Employee
Go to the query editor, highlight both 2016 and 2017 columns (shift + mouse click), then click "unpivot columns" in the Transform tab. This will give you 2 columns: budget and year. Notice how your rows for project number have doubled, with a row for 2016 and a row for 2017. Now you can create a chart with the budget field for the value, and add a slicer with budget year as field that will filter the chart.
- mvmania9 years agoRegular Visitor
Thank you very much for this simple and great solution.
You saved me!