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

Calling all Data Engineers! Fabric Data Engineer (Exam DP-700) live sessions are back! Starting October 16th. Sign up.

Reply
Shloka_Lakhani
Frequent Visitor

how to filter data based Run date is relative date Compare date is null or relative date

Hello, 

My aggregate table is like:

DateComapny NameTotal CountsLive countsInactive counts changes in live countschanges in inactive counts
30-junePQR100802000
1-julyABC80404000
1-julyPQR9590500
2-julyABC1202010000
2-julyPQR9590500

 

Now, i create two date filters from date column 1) Run date   2) Compare date

 

Note : always Compare date should be equal or lesser than the run date in date filter.

 

Changes column work like run date counts - compare date counts

 

example 1: My run date is 2-july and compare date is 1- july, i want result like:

 

DateCompany NameTotal Counts  Live Counts  Inactive counts   changes in live counts   changes in inactive counts
2-julyABC12020100-2060
2-julyPQR9590500

 

example 2: My run date is  1-july and compare date is 30- june, i want result like:

 

DateComapny NameTotal CountsLive counts   Inactive counts   changes in live counts    changes in inactive counts
1-julyABC80404000
1-julyPQR9590510-15

 

Concenr is:  for example 2 dates Company ABC data is not showing in table. 

1 REPLY 1
amitchandak
Super User
Super User

@Shloka_Lakhani , with help from date table you can create DOD measures

 

example

 

This Day = CALCULATE(sum('Table'[Qty]), FILTER(ALL('Date'),'Date'[Date]=max('Date'[Date])))
Last Day = CALCULATE(sum('Table'[Qty]), FILTER(ALL('Date'),'Date'[Date]=max('Date'[Date])-1))
Last Day = CALCULATE(sum('Table'[Qty]), previousday('Date'[Date]))

 

 

 

Day Intelligence - Last day, last non continous day
https://medium.com/@amitchandak.1978/power-bi-day-intelligence-questions-time-intelligence-5-5-5c324...

 

or do it using two selections?

 

Power BI How to use/compare two Date/Period slicers: https://youtu.be/WSeZr_-MiTg

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
FabCon Global Hackathon Carousel

FabCon Global Hackathon

Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes!

September Power BI Update Carousel

Power BI Monthly Update - September 2025

Check out the September 2025 Power BI update to learn about new features.

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.

Top Solution Authors
Top Kudoed Authors