Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.
Hi Folks,
Thanks for addressing my query.
I need that my slicer will auto select the latest date from the drop down list. Is there any solutions??
Thanks,
Gaurav Jangra
Solved! Go to Solution.
@gauravjangra09 , That is where you need to have column like
Date Type = SWITCH(TRUE(),'Date'[Date]=max(Table[Date]),"Lastest Date" //Date equal to max of fact/table
,'Date'[Date]&"")
Hi @Anonymous
If you want to get the latest date by slicer, you can build a measure.
Due to I don't know your data model, I build a sample to have a test.
Measure:
M.Value =
VAR _Value =
SUM ( 'Table'[Value] )
VAR _LatestDate =
MAXX ( ALL ( 'Table' ), 'Table'[Date] )
VAR _LatestValue =
CALCULATE (
SUM ( 'Table'[Value] ),
FILTER ( 'Table', 'Table'[Date] = _LatestDate )
)
RETURN
IF ( ISFILTERED ( Sclier[Slicer] ), _LatestValue, _Value )
In table visual it will show all Dates as default and show the latest Date if you select the Slicer.
You can download the pbix file from this link: Select latest date from the table in the slicer
Best Regards,
Rico Zhou
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
@Anonymous , There no auto select option.
You have to use one of these tricks. Have a column like this and select the value. Sort this column on date column
new Columns
Date Type = SWITCH(TRUE(),'Date'[Date]=TODAY(),"Today"
,'Date'[Date]=TODAY()-1,"Yesterday"
,'Date'[Date]&"")
Date Type = SWITCH(TRUE(),'Date'[Date]=Max('Table'[Date]),"Lastest Date"
,'Date'[Date]&"")
Hi @amitchandak
Thanks for your reply.
This case is acceptable when data is updating regularly what should i do when i didn't have the latest data.
let suppose in my table i have latest record is for 13th September. then how i will address this.
Thanks,
Gaurav Jangra
@gauravjangra09 , That is where you need to have column like
Date Type = SWITCH(TRUE(),'Date'[Date]=max(Table[Date]),"Lastest Date" //Date equal to max of fact/table
,'Date'[Date]&"")
Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.
User | Count |
---|---|
110 | |
94 | |
81 | |
66 | |
58 |
User | Count |
---|---|
150 | |
119 | |
104 | |
87 | |
67 |