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

Get Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now

Reply
Anonymous
Not applicable

Comparing all available expiry dates in dataset with the date derived using measure

Hi All,

I have a Medicine_Master table with a column - "Expiry Date". I want to compare these expiry dates with a derived date using the measure. This data is to be represented using the Table visual.

 

The following are some basic dates:
          1) Analysis Date = First date of the selected month and year using respective slicers.
          2) Future Comparison Date = Analysis Date + 7 months (This date is calculated using measure: EOMONTH(Analysis Date, 7)

Now, the condition is that, if an "Expiry Date" is less than or equal to the "Future Comparison Date", the 'Will Expire?' will be 'Yes' otherwise 'No'.


This comparison will be done for all 'Lot Numbers' existing in the data table. This data is to be furnished in the Table visual.

 

Dynamic_Date_Comparison.png

 

In the screen shot, all expiry dates are shown in the 'Plan Expiry Date' column. This date is to be compared with 'Future Comparison Date'. And comparison result is to be displayed in the 'Will Expire?' column. You can see that the first 3 rows having the plan expiry date should be having 'Yes' instead of 'No'!!


When I select May-2023, the first three rows shoul show 'Yes' in 'Will Expire?' column.


When I select Oct-2023, all the lot numbers having planned date less than Jun-2024 should show 'Yes'.

I have tried a lot to get the desired output but failed every time!! Please help me to get it done!

@amitchandak: Hello sir... 🙂. Please help me with this.

1 REPLY 1
Anonymous
Not applicable

Hi @parry2k / @amitchandak

Please help me on this. 🙂

Helpful resources

Announcements
November Power BI Update Carousel

Power BI Monthly Update - November 2025

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

Fabric Data Days Carousel

Fabric Data Days

Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!

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