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
pantherfanrh
Frequent Visitor

Graph values between dates?

I have two values, open, and close date. I would like to show a graph showing how many stores were open at that certain date. So something like the x axis would be dates, and the y axis would be how many places were open at those dates. But I wasn't sure how to make the column do that. Any help would be appreciated!

1 ACCEPTED SOLUTION
v-qiuyu-msft
Community Support
Community Support

@Greg_Deckler Great idea. Smiley Happy

 

@pantherfanrh I would like to make @Greg_Deckler's suggestion more perfect. Assume the end date is blank, means the store still open until now. So we can create a measure like this:

 

Measure = CALCULATE(COUNTA(Table1[Store]),FILTER(ALL(Table1),'Table1'[Open]<=MAX('Calendar'[Date]) && ('Table1'[Close]>MAX('Calendar'[Date])|| 'Table1'[Close]=BLANK())))

 

q1.PNG

 

Please download attached .pbix file to have a look.

 

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

3 REPLIES 3
v-qiuyu-msft
Community Support
Community Support

@Greg_Deckler Great idea. Smiley Happy

 

@pantherfanrh I would like to make @Greg_Deckler's suggestion more perfect. Assume the end date is blank, means the store still open until now. So we can create a measure like this:

 

Measure = CALCULATE(COUNTA(Table1[Store]),FILTER(ALL(Table1),'Table1'[Open]<=MAX('Calendar'[Date]) && ('Table1'[Close]>MAX('Calendar'[Date])|| 'Table1'[Close]=BLANK())))

 

q1.PNG

 

Please download attached .pbix file to have a look.

 

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.

This was so helpful! It worked perfectly. Thank you so much!

Greg_Deckler
Super User
Super User

Probably a similar solution that I suggested here:

https://community.powerbi.com/t5/Desktop/Number-of-members-to-any-date/m-p/180695

 


@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
The Definitive Guide to Power Query (M)

DAX is easy, CALCULATE makes DAX hard...

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.