March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount! Early bird discount ends December 31.
Register NowBe one of the first to start using Fabric Databases. View on-demand sessions with database experts and the Microsoft product team to learn just how easy it is to get started. Watch now
I have payment date column and trying to create slicer with between. Bu when I select date from slicer it empties table. any work around?
Solved! Go to Solution.
Hi @annam
My solution is to add missing dates in the source data and fill in the amount as “BLANK”.
In this way, when using a slicer with between, there will be no interval dates that cause visual objects to be empty.
CompleteTable = ADDCOLUMNS(
CROSSJOIN(
CALENDAR(MIN(Payment[Date]), MAX(Payment[Date])),
DISTINCT(Payment[Name])),
"Amount",
COALESCE(LOOKUPVALUE(Payment[Amount],Payment[Date],[Date]), BLANK())
)
Create a one-to-many relationship from table“Payment” to table“CompleteTable” by “Date” columns.
Put “Date”, “Amount” from table“CompleteTable” and “Name” from table“Payment” into the visual object. Put “Date” from table“CompleteTable” into the slicer.
Here is my final test result.
I hope this solution meets your requirements.
Best Regards,
Jarvis Tang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi @annam
My solution is to add missing dates in the source data and fill in the amount as “BLANK”.
In this way, when using a slicer with between, there will be no interval dates that cause visual objects to be empty.
CompleteTable = ADDCOLUMNS(
CROSSJOIN(
CALENDAR(MIN(Payment[Date]), MAX(Payment[Date])),
DISTINCT(Payment[Name])),
"Amount",
COALESCE(LOOKUPVALUE(Payment[Amount],Payment[Date],[Date]), BLANK())
)
Create a one-to-many relationship from table“Payment” to table“CompleteTable” by “Date” columns.
Put “Date”, “Amount” from table“CompleteTable” and “Name” from table“Payment” into the visual object. Put “Date” from table“CompleteTable” into the slicer.
Here is my final test result.
I hope this solution meets your requirements.
Best Regards,
Jarvis Tang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi @annam
Why not use a Date Table?
Create an Active One to Many relationship from the Date column in the Date table to the payment date column in your table.
Create a slicer from the Date column in the date table and use the columns from the Data table in a visual that has a measure from your table.
Hope this helps
Joe
Proud to be a Super User! | |
Date tables help! Learn more
March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!
Arun Ulag shares exciting details about the Microsoft Fabric Conference 2025, which will be held in Las Vegas, NV.
User | Count |
---|---|
21 | |
18 | |
17 | |
7 | |
5 |
User | Count |
---|---|
31 | |
27 | |
19 | |
13 | |
12 |