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
RUPSY777
Helper II
Helper II

Display data using date slicer having multiple

For a user given date range(single column)display data

 

Requirement:
starting before the start date and ending at the end date
starting before the start date and ending before the end date
starting after the start date and ending before the end date
starting after the start date and ending after the end date
starting and ending within the date range
starting and ending at the specified range

 

data available
A table contains the cols as(with other cols not relevant to the problem)
Start Date
End Date
Inventory item

2 ACCEPTED SOLUTIONS
amitchandak
Super User
Super User

@RUPSY777 , With an independent date table

 

measure =
var _max = maxx(allselected('Date'), 'Date'[Date])
var _min = minx(allselected('Date'), 'Date'[Date])
return
calculate(count(Table[Inventory item]), filter(Table, Table[Start Date] >=Min && Table[End Date] = _max))

 

same way build others 

 

Join us as experts from around the world come together to shape the future of data and AI!
At the Microsoft Analytics Community Conference, global leaders and influential voices are stepping up to share their knowledge and help you master the latest in Microsoft Fabric, Copilot, and Purview.
️ November 12th-14th, 2024
 Online Event
Register Here

View solution in original post

v-easonf-msft
Community Support
Community Support

Hi, @RUPSY777 

The information you have provided is not making the problem clear to me. Can you please explain with an example.

Please share some sample data( in excel ) and expected result.It will help to provide the appropriate solution. 

 

Best Regards,
Community Support Team _ Eason

 

View solution in original post

3 REPLIES 3
v-easonf-msft
Community Support
Community Support

Hi, @RUPSY777 

The information you have provided is not making the problem clear to me. Can you please explain with an example.

Please share some sample data( in excel ) and expected result.It will help to provide the appropriate solution. 

 

Best Regards,
Community Support Team _ Eason

 

amitchandak
Super User
Super User

@RUPSY777 , With an independent date table

 

measure =
var _max = maxx(allselected('Date'), 'Date'[Date])
var _min = minx(allselected('Date'), 'Date'[Date])
return
calculate(count(Table[Inventory item]), filter(Table, Table[Start Date] >=Min && Table[End Date] = _max))

 

same way build others 

 

Join us as experts from around the world come together to shape the future of data and AI!
At the Microsoft Analytics Community Conference, global leaders and influential voices are stepping up to share their knowledge and help you master the latest in Microsoft Fabric, Copilot, and Purview.
️ November 12th-14th, 2024
 Online Event
Register Here

Hi thank you for your response..

Can you refer to which date you are referring to in the below highlighted syntax?

var _max = maxx(allselected('Date'), 'Date'[Date])

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!

November Carousel

Fabric Community Update - November 2024

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

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.