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

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
Jay12
New Member

Dax

I have an issue:

I have:

1. IDs (this contains nvarchar ID)

2. Stage (This is the stage of each ID at different dates)

3. Import_Date: This is a date value for all ID.

 

I want to create dax measures for a visual:

2 separate date filters for Import_Date

 

A visual to show:

In column A: IDs

In column B: Early Stage only (This should contain only data for the minimum user selected date)

 

In column C: Later Stage only (This should contain only data for thr maximum user selected Date).

 

 

Basically, I want to view only data for the selected dates, not before or after the date. 

 

Example, if a user selects 6/10/2022 and 13/1/2023, the visual will show this pattern. 

ID-440 || Stage_7 || Stage_9

1 REPLY 1
amitchandak
Super User
Super User

@Jay12 , Based on what I got a new column

 

Next =

var _min = minx(filter(Table , [ID] = earlier([ID]) && [Import Date] > earlier([Import Date]) ), [Import Date])

return

minx(filter(Table , [ID] = earlier([ID]) && [Import Date] =_min ), [Stage])

 

previous=

var _max = maxx(filter(Table , [ID] = earlier([ID]) && [Import Date] < earlier([Import Date]) ), [Import Date])

return

minx(filter(Table , [ID] = earlier([ID]) && [Import Date] =_max ), [Stage])

 

Power BI DAX- Earlier, I should have known Earlier: https://youtu.be/CVW6YwvHHi8

Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!

December 2025 Power BI Update Carousel

Power BI Monthly Update - December 2025

Check out the December 2025 Power BI Holiday Recap!

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.