Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!Calling all Data Engineers! Fabric Data Engineer (Exam DP-700) live sessions are back! Starting October 16th. Sign up.
Hi
I am working with a sett of data that tells me at what time a certain product will expire. I have the number of days untill the expiering day, but I wish to represent it as number of months. Also, if it is possible I want Power BI to show me the exact expiering date.
In advance, thank you for all your advices!
Solved! Go to Solution.
If you have the number of days from today until the expiry you could do something like the following to calculate the expiry date
Expiry Date = UTCNow() + DaysTilExpiry
Then you can calculate the difference between now and the expiry date in months using the DATEDIFF function
Expiry Months = DATEDIFF( utcnow(), [Expiry Date], MONTH)
If you have the number of days from today until the expiry you could do something like the following to calculate the expiry date
Expiry Date = UTCNow() + DaysTilExpiry
Then you can calculate the difference between now and the expiry date in months using the DATEDIFF function
Expiry Months = DATEDIFF( utcnow(), [Expiry Date], MONTH)
Perfect, thank you! 🙂
Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes!
Check out the October 2025 Power BI update to learn about new features.