Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Be one of the first to start using Fabric Databases. View on-demand sessions with database experts and the Microsoft product team to learn just how easy it is to get started. Watch now

Reply
ThomasHOL
New Member

Dynamic names in graph and some sorting

I’m quite new to PowerBI so please forgive me if the question I’m asking has been answered 50 before, but I couldn’t find any solution i could use.

I’m building up some reports and one based on our rolling forecast is causing me some headaches. The problem I have lies in both the sorting and the names of the graph. Let me post a schreenshot of what I got (sorry for the Danish language).

 
graf.png


So what I tried to do is to make a graph of realized revenue last year, realized this year and the the next 8 budget periods. But because the name of last year is later in the alphabet it gets sorted after the periods. I know I could properly add a extra colum in the datasource and simply enter number 1-10 on the colums I need sorted. But I guess that I will need the data In other reports so it would be better to be able to dynamically sorting it.


The other problem is that I’m uploading this data to a database every month so period 1 wil differ each month and it would be good to have May 16 instead of “Periode 1” June instead of “Periode 2” etc.  and renaming the upload fields wont really be of any use as next month “Periode 1” should be June 16 etc. So I hope that some of you can give me a good way around these problems.

Right now my data structure is like this.

 

Type  - Period – Project – Type – Value – Text field

Type: is where I define the fields ex “Periode 1”
Period: end of the current period
Project: This defines what project I want to show the report for.
Type: We have several different types of data each month.
Value: This is where I enter the data ex the forecasted revenue for the period.
Text field: we have some extra information in text.

I look forward to hearing from you.  

3 REPLIES 3
asocorro
Skilled Sharer
Skilled Sharer

I am not sure I understand the whole scenario, but here goes an answer.  To be able to have a chart with the most recent 8 periods, in the Query Editor you can sort your data by the date column, and then add an Index column, which you will then use to filter your chart.  For example< here I sorted by PersonFullName and then added the index column:

 

i.png

 

To chart the top 8:

 

f.png

Connect with me in LinkedIn: https://pr.linkedin.com/in/adolfosocorro
Follow me on Twitter: https://twitter.com/AdolfoSocorro
ThomasHOL
New Member

are there really nobody that can help me?

@ThomasHOL

 

Currently, in Power BI Desktop, it's only supported to sort a chart based on a column. I don't think there's any better way than adding an index column for sorting.

 

Change how a chart is sorted in a Power BI report

 

I would recommend you submit a feature request on: https://ideas.powerbi.com/forums/265200-power-bi-ideas

 

Regards,

Helpful resources

Announcements
Las Vegas 2025

Join us at the Microsoft Fabric Community Conference

March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!

Dec Fabric Community Survey

We want your feedback!

Your insights matter. That’s why we created a quick survey to learn about your experience finding answers to technical questions.

ArunFabCon

Microsoft Fabric Community Conference 2025

Arun Ulag shares exciting details about the Microsoft Fabric Conference 2025, which will be held in Las Vegas, NV.

December 2024

A Year in Review - December 2024

Find out what content was popular in the Fabric community during 2024.