Forum Discussion
smbolster
8 years agoFrequent Visitor
Problem With Calculate Measure
I'm having an issue with max date in a calulate measure that seems like it should work. The measure I'm starting with is as follows: Months In Selection= CALCULATE(COUNTROWS(VALUES('Real Date...
- 8 years ago
Try this
Months In Selection New = CALCULATE ( COUNTROWS ( VALUES ( 'Real Dates'[Date Accounting Period] ) ), FILTER ( ALL ( 'Real Dates' ), 'Real Dates'[Date] <= [Max Accounting Period] ) )
Zubair_Muhammad
8 years agoCommunity Champion
Try this
Months In Selection New =
CALCULATE (
COUNTROWS ( VALUES ( 'Real Dates'[Date Accounting Period] ) ),
FILTER ( ALL ( 'Real Dates' ), 'Real Dates'[Date] <= [Max Accounting Period] )
)- smbolster8 years agoFrequent Visitor
Months In Selection New = CALCULATE ( COUNTROWS ( VALUES ( 'Real Dates'[Date Accounting Period] ) ), FILTER (VALUES ( 'Real Dates'[Date Accounting Period] ), 'Real Dates'[Date Accounting Period] <= [Max Accounting Period] ) )
That helped steer me, this is what i used, which allowed filters on the screen to work, like if i pick 2017 it returns 12.
Thanks