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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
PrernaPedamkar
Frequent Visitor

Display bar chart/line chart result as per date range selection (month wise, week wise, day wise).

Hello All,

 

I am a beginner in PowerBI, I require help for one of the requirements :

 

Display bar chart/line chart result as per date range selection (month wise, week wise, day wise).

If date range selection > 1 month, show chart in months.

If it's < 1 month, show chart in weeks.

If it's < 1 week, show chart in days. 

 

screeshot.png 

How can this be achieved in PowerBI desktop (November update)? Or a work around for the same will also do.

Thanks in advance !

2 ACCEPTED SOLUTIONS

Hi @PrernaPedamkar,

 

Date hierarchy doesn't contain week automatically. You need to create a calculated column to calculate the weeknum values. You can download the attached .pbix in my original post to have a look.

 

q3.PNG

 

 

Best Regards,
Qiuyun Yu

Community Support Team _ Qiuyun Yu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

Ok Sure.  I am definitely going to work upon this work around.  Thanks !

View solution in original post

9 REPLIES 9
v-qiuyu-msft
Community Support
Community Support

Hi @PrernaPedamkar,

 

Based on my research, it's not supported to change chart X-axis field dynamically based on the selected range in a slicer.

 

In your scenario, you can drag a Month, Week, Date fields into Axis property, when you checked different date range in a slicer visual, you are able to see values in different hierarchies manually.  For more information, see:  Visual hierarchies and drill-down behavior.

 

q2.PNGq3.PNG

 

Best Regards,
Qiuyun Yu

Community Support Team _ Qiuyun Yu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Hi @v-qiuyu-msft,

 

Thanks for the reply.  I'll surely work upon the suggestion.  However, for displaying weekwise data I donot see week hierarchy for my date column (Column Updated- refer below screenshot).  Do I have to create a separate date table or is there any other workaround?

screeshot2.png

 

Thank you again for the help. 🙂

 

 

 

 

Hi,

 

I'm new on this forum.

Where can i find the attachment?

 

Thanks


Tolga

 

I found it 🙂

 

Thanks

Hello, I am wondering where I can fin the attachment. Sorry, I just recently used this tool.

Hi @PrernaPedamkar,

 

Date hierarchy doesn't contain week automatically. You need to create a calculated column to calculate the weeknum values. You can download the attached .pbix in my original post to have a look.

 

q3.PNG

 

 

Best Regards,
Qiuyun Yu

Community Support Team _ Qiuyun Yu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Okay.  Thanks @v-qiuyu-msft for the help ! 🙂

 

Regards,

Prerna

Hi @PrernaPedamkar,

 

Are you satisfied with our response? If that is a case, would you please mark a proper reply as an answer so that we can close the thread? If you have any question, please feel free to ask.

 

Best Regards,
Qiuyun Yu

Community Support Team _ Qiuyun Yu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Ok Sure.  I am definitely going to work upon this work around.  Thanks !

Hi @PrernaPedamkar,

 

Please mark a post which is the solution to the question as an answer. It will benefit other communities who has the seem issue to find the answer.

 

Best Regards,
Qiuyun Yu

Community Support Team _ Qiuyun Yu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.