Forum Discussion
Stuznet
Helper V
8 years agoFilter Year Dynamically without Slicer
Hi guys, I'm having problem filtering the year dynamically without using my slicer. I'm summing the total of IDs for this year. I could add the year in the page filter but I don't want to...
- 8 years ago
Many times, this is handled in the data or a measure via something along the lines of (column form):
Column = IF(YEAR(TODAY())=YEAR([Date]),1,0)
Then you just filter on 1
- 8 years ago
Greg_DecklerThank you :) I was able to get the correct count.
This is what I did
1) Create new column
Column = IF(YEAR(TODAY()) = YEAR([columnDate]),1,0)
2) Create new measure
Measure = CALCULATE(SUM(Table1[measure]),FILTER(Table1,Table1[Column]))
Greg_Deckler
Community Champion
8 years agoMany times, this is handled in the data or a measure via something along the lines of (column form):
Column = IF(YEAR(TODAY())=YEAR([Date]),1,0)
Then you just filter on 1
- Stuznet8 years ago
Helper V
Greg_DecklerThank you :) I was able to get the correct count.
This is what I did
1) Create new column
Column = IF(YEAR(TODAY()) = YEAR([columnDate]),1,0)
2) Create new measure
Measure = CALCULATE(SUM(Table1[measure]),FILTER(Table1,Table1[Column]))