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

Level up your Power BI skills this month - build one visual each week and tell better stories with data! Get started

Reply
lexxonnet
New Member

Display records effective on a specific date

I have an interesting conundrum, and I've tried a number of different approaches on the PowerBI forum and none really seem to help me crack this one.

 

I am trying to visualise a table, with a date filter that allows me to show which records are active on a specific date.

The table has the fields Effective From and Effective To which are date fields.

 

I've created a new date table, unlinked to the current one, as below:

lexxonnet_0-1668211045911.png

The measure SelValue in that table is set to MAX(CountriesDatePicker[Date]), which in itself is set using a slicer as below: 

lexxonnet_1-1668211110532.png

 

Now, the actual table uses a measure with the following formula to set if a record is active or inactive on the specific date:

 

Entry status = IF(Countries[Effective From] <= CountriesDatePicker[SelValue] && Countries[Effective To] >= CountriesDatePicker[SelValue] , "Active", "Inactive")
 
With the above - I'd expect this row (highlighted) to be listed as 'Active' when the selected value is in 2006, however, it is inexplicably inactive!
lexxonnet_2-1668211192443.png

 

Would appreciate any insights! The filter only ever seems to work when I set the filter to the latest date (i.e., today).

 

2 REPLIES 2
Ashish_Mathur
Super User
Super User

Hi,

The ideal approach would be create one row for every data that lies betweenthe Effective From and Effective To dates.  The create a relationship (Many to One and Single) from the newly created date column to the date column of the Calendar Table.


Regards,
Ashish Mathur
http://www.ashishmathur.com
https://www.linkedin.com/in/excelenthusiasts/
amitchandak
Super User
Super User

@lexxonnet , It Should follow the HR Blog  logic

https://community.powerbi.com/t5/Community-Blog/HR-Analytics-Active-Employee-Hire-and-Termination-tr...

 

file is attached

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
April Power BI Update Carousel

Power BI Monthly Update - April 2026

Check out the April 2026 Power BI update to learn about new features.

Fabric SQL PBI Data Days

Data Days 2026 coming soon!

Sign up to receive a private message when registration opens and key events begin.

New to Fabric survey Carousel

New to Fabric Survey

If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.

Power BI DataViz World Championships carousel

Power BI DataViz World Championships - June 2026

A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.