The ultimate Microsoft Fabric, Power BI, Azure AI, and SQL learning event: Join us in Stockholm, September 24-27, 2024.
Save €200 with code MSCUST on top of early bird pricing!
Find everything you need to get certified on Fabric—skills challenges, live sessions, exam prep, role guidance, and more. Get started
Hello All , Kindly i need to have yesterday date for last year based on slected month from Dim_Date slicer
So as an example
if i chosed May 2023 yesterday will be 2022-06-05
if i chosed April 2023 yesterday will be 2022-04-05
Solved! Go to Solution.
Hi @AhmedHassan
Please try
Yesterday Date =
VAR SelectedDate =
MAX ( Dim_Date[Date] )
VAR TodayDate =
TODAY ()
RETURN
DATE ( YEAR ( SelectedDate ) - 1, MONTH ( SelectedDate ), DAY ( TodayDate ) - 1 )
Hi @AhmedHassan
Please try
Yesterday Date =
VAR SelectedDate =
MAX ( Dim_Date[Date] )
VAR TodayDate =
TODAY ()
RETURN
DATE ( YEAR ( SelectedDate ) - 1, MONTH ( SelectedDate ), DAY ( TodayDate ) - 1 )
Hello @tamerj1
you saved my day , cannot thank you enough. many thanks and much appreciated
Join the community in Stockholm for expert Microsoft Fabric learning including a very exciting keynote from Arun Ulag, Corporate Vice President, Azure Data.
Check out the August 2024 Power BI update to learn about new features.
User | Count |
---|---|
19 | |
19 | |
18 | |
15 | |
11 |
User | Count |
---|---|
35 | |
34 | |
19 | |
19 | |
14 |