Power BI Fiscal Year?Hack
The Problem
I was presented with a requirement where the charts and slicers in the Power BI dashboard were to be sorted according to the fiscal year. This meant that the charts which started in January and ended in December were to be sorted according to the company’s fiscal year start and end. Their fiscal year began in July and ended in June next year.
The magic begins?here
I created a conditional column in Power Query where I replaced the values. July became 1, August became 2, September 3, and so on. This got me a new column which I renamed “FY Months”.
Then comes the magic trick. Select the column which you want to sort which in my case was “Month” which was in the data initially.
Click on the said field which will open a new bar at the top of the taskbar.
Select “Sort by Column” and then select the FY Months fields.
Say Abra Kadabra and you will have your charts and slicers sorted accordingly.
Here is how my charts and slicers displayed after this:
Look how the line chart is starting from July rather than its usual practice which is starting from January
The point to note is that the slicer is also displaying the first value to be July rather than January.
This is how I changed my dashboard from January to December into July to June according to the requirements.
Basharat, over and out.
PS: I know you like everything in HD but for the time being you have to work with my ultra HD screenshots which give you the classic feel of old Nokia phones. Hehe.
Driving change through data & finance business partnering ? ~15 years of leading teams in Finance, Data Analytics, Strategy ? VP Commercial Finance
1 年That's indeed a 2-minute read. Easy and clear. The only things that are not clear are some of the screenshots which, as you said, remind us of Nokia phones ?? But despite that, everything makes sense Syed Ahmed Basharat Ali !