Advance your Data & AI career with 50 days of live learning, dataviz contests, hands-on challenges, study groups & certifications and more!
Get registeredGet Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Learn more
Hello,
I try to slice events by date. I use a date table.
Cardinalite seems right.
When I change the start date, the data disapear from the visual.
When I change the end date, nothing happens.
The other slicers work fine.
Dates are some format in both tables.
.
How to solve that situation?
Solved! Go to Solution.
The root of the problem the date format originating of Power Query.
For more information on how to resolve it, see this video.
Relationship Issues With DateTime Data Types in Power BI (youtube.com)
Hi @PierreCA ,
According to you, the reason for this is that the data disappears in the first place because it doesn't exist in this range. I've noticed that your calendar table has a lot of data, which will result in a lot of blank dates, which will result in a large blank date between your slicer end date and the actual end date, and it looks like the slicer isn't working. Based on this understanding, you can create a calendar with the start and end of the actual date.
Table 2 = CALENDAR(MIN('Table'[DateNotification]),MAX('Table'[DateNotification]))
Final output
Best regards,
Albert He
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly
@PierreCA Does your calendar table have a row for every single date? Are your dates DATE ONLY (no time)?
Your screenshots show 2024 and 2023 dates - do both tables contain the same dates?
Copying DAX from this post? Click here for a hack to quickly replace it with your own table names
Has this post solved your problem? Please Accept as Solution so that others can find it quickly and to let the community know your problem has been solved.
If you found this post helpful, please give Kudos C
I work as a Microsoft trainer and consultant, specialising in Power BI and Power Query.
www.excelwithallison.com
Hello @AllisonKennedy and @Anonymous ,
To buil the date reference table, I use the folllowing code:
CalendrierSurveillant =
VAR varAnneDebut = Year(MIN(Notification[dateNotification]))
VAR varAnneFin = Year(MAX(Notification[dateNotification]))
RETURN
ADDCOLUMNS(
FILTER(
CALENDARAUTO(),
YEAR([Date])>=varAnneDebut &&
YEAR([Date])<=varAnneFin
),
"Année", YEAR([Date]),
"Semestre #", IF( OR( INT(FORMAT([Date],"q"))=1 , INT(FORMAT([Date],"q"))=2),1,2),
and so on ....)
The other table doesn't contain all the equivalent dates, but should be in the same year range.
There's no time reference, @AllisonKennedy , and the format is the same in both table: short date.
There's no blank row in either table.
If I understand you, @Anonymous , I should limit the date creation to the actual dates in the table Notification and use CALENDAR function instead of CALENDARAUTO. Am I right?
But after that small change, I get the same result. The visual disapears.
CalendrierSurveillant =
VAR varAnneDebut = MIN(Notification[dateNotification])
VAR varAnneFin = MAX(Notification[dateNotification])
RETURN
ADDCOLUMNS(
CALENDAR(varAnneDebut,varAnneFin),
"Année", YEAR([Date]), ....)
The root of the problem the date format originating of Power Query.
For more information on how to resolve it, see this video.
Relationship Issues With DateTime Data Types in Power BI (youtube.com)
Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!
Check out the October 2025 Power BI update to learn about new features.