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.
I have the following slicer:
When i select an id linked to the slicer that doesn't have any data for 'Today' I get the following:
I would like the slicer to have all options no matter what id is selected.
This is the slicer query:
let
Source = let
TodaysDate = Date.From(DateTimeZone.FixedUtcNow()),
Ranges = {
{"Today",
TodaysDate,
TodaysDate,
1},
{"WTD",
Date.From(Date.StartOfWeek(TodaysDate)),
TodaysDate,
2},
{"MTD",
Date.From(Date.StartOfMonth(TodaysDate)),
TodaysDate,
3},
{"QTD",
Date.From(Date.StartOfQuarter(TodaysDate)),
TodaysDate,
4},
{"YTD",
Date.From(Date.StartOfYear(TodaysDate)),
TodaysDate,
5}
},
GetTables = List.Transform(Ranges,
each CreatePeriodTable(_{0}, _{1}, _{2}, _{3})),
Output = Table.Combine(GetTables)
in
Output
in
Source
with this function:
let
Source = (
PeriodName as text,
StartDate as date,
EndDate as date,
SortOrder as number
) as table =>
let
DayCount = Duration.Days(EndDate-StartDate)+1,
DateList = List.Dates(StartDate,DayCount,#duration(1,0,0,0)),
AddPeriodName = List.Transform(DateList,
each {PeriodName,_,SortOrder}),
CreateTable = #table(
type table[Period=text, Date=date, Sort=number],
AddPeriodName)
in
CreateTable
in
Source
@MFelix - i have seen your answer on something like this before. Are you able to help with display of the slicer?
Thank you
Solved! Go to Solution.
Hello @rdc_green ,
Try to do this.
Another way is to make the fields of the two slicers come from two unrelated tables.
Best regards
Lionel Chen
If this post helps,then consider Accepting it as the solution to help other members find it faster.
Unfortunatley I don't have the option to turn interactions off for that slicer:
Hello @rdc_green ,
Try to do this.
Another way is to make the fields of the two slicers come from two unrelated tables.
Best regards
Lionel Chen
If this post helps,then consider Accepting it as the solution to help other members find it faster.
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 |
---|---|
109 | |
98 | |
77 | |
66 | |
54 |
User | Count |
---|---|
144 | |
104 | |
101 | |
86 | |
64 |