Forum Discussion
Date slicer is not changing date when selecting other slicer
- Anonymous3 years ago
Hello all,
Just for your information the solution applied was:
1) Created required slicers
2) Go to Format3) Selecting Department, enable filter bottom of Date Slicer
Neither any additional tables.
I've checked using bi-directional relationship and it worked. But then i've tried removing this bi-directional relationship and it worked also. I don't know if it worked without bi-directional relationship, but maybe data as it's cached and if data is updated it'll fail.
Anyway, the general solution is proposed one and with bi-directional relationship.
Thanks a lot to everyone for feedback
Power BI is using their own Date table in the backround to set the values for the Slicer, and likely using a max and a min date from your dataset as the starting and ending points. At a high level, I would create a custom date table (find one in PBI community), mark it as your date table in the modeling tab, and then allow the tile filter to filter that date table. In order to avoid data errors, I would split out a seperate table for the distinct categories/date combos (parent data) which will require some Power Query knowledge, and the have it BI directionally cross filter with the date table, that then filters the values table, as I would call it the record table. Make sure the tile filter is set to the field from the categories/date combos table according to the model imaged below.
Note that, as mentioned by lbendlin , this is really a bum requirement, and should be avoided unless some client simply can't live without. If your model is more complex, bi-directional filtering like this could cause ambiguous relationships, although I do not think bi-directional is necessarily needed in this case.
The multi table idea was not needed as I reviewed this solution. A simpe bi - directional filter gets the job done... but this will only be effective if you set at the visual level that the date filter cannot effect the Tile filter. Updated model below
If your data model really is that simple, this should behave "fine", but if you have a lot of data sources and tables being joined relationally, you need to be careful with this.