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
Anonymous
Not applicable

Grouping column values

sjpusat_0-1680289853443.png

This is the visual I am currently working on, tracking aging tickets. The X-axis is derived from a Measure I created called "DaysSinceOpen" which is just a measure of DateDiff of the created date to today. I'd like to be able to get that DaysSinceOpen field on the X axis grouped into columns, for example the first column would be "1-7 days" and the next would be 8-15 days and so on. Here's a screenshot of the fields:

sjpusat_1-1680290227100.png

If anyone knows how to accomplish this that would be greatly appreciated, as I am still pretty new to PowerBI. Thanks!

1 ACCEPTED SOLUTION
DOLEARY85
Super User
Super User

You could try wrapping the datediff in if statements: e.g for 1-7 days 

 

Dayssinceopen = if(DATEDIFF(MAX('Table'[created date]),today(),DAY)<8,"1-7","more")
 
then just add more conditions,
 
hope this helps

View solution in original post

1 REPLY 1
DOLEARY85
Super User
Super User

You could try wrapping the datediff in if statements: e.g for 1-7 days 

 

Dayssinceopen = if(DATEDIFF(MAX('Table'[created date]),today(),DAY)<8,"1-7","more")
 
then just add more conditions,
 
hope this helps

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.