With all of the slicers set to All, the values for each of these measures is as follows:
Measure |
Value |
Explanation |
Days |
1096 |
This measure counts all of the rows in the table (366 + 365 + 365). |
January Days |
93 |
This measure only counts days in the table with a month of January (31 + 31 + 31). |
January Wednesday Days |
13 |
This measure only counts days in January that are Wednesdays (5 + 4 + 4). |
All Days |
1096 |
This measure always counts all of the rows in the table (366 + 365 + 365). |
Weekday Days |
1096 |
This measure counts all of the rows in the table unless there is a weekday filter (366 + 365 + 365). |
All Years January Days |
93 |
This measure counts days in January, ignoring filters for Year, but not other filters. |
January Days? |
93 |
This measure only counts days in January. |
January Days! |
93 |
This measure only counts days in January. |
For January Days?, it may appear odd that this measure calculates the number of days in January for the three years of dates listed in the table since the outer CALCULATE function clearly specifies a filter of February. However, the default behavior of CALCULATE is to use the innermost filter value when the same column is specified within nested CALCULATE statements.
Given the default behavior of the CALCULATE function, it may seem even more odd that the January Days! measure also returns the number of days in January. The reason for this is the KEEPFILTERS function. The KEEPFILTERS function changes the default behavior of the CALCULATE function by adding another filter. The calculation now becomes the intersection of the two filters instead of a complete override. Thus, since the only value that is in common between the two filters is January, only the count of the days in January is returned!