Forum Discussion
Anonymous
8 years agoNot applicable
Using ALLEXCEPT or ALL not working
Hello, Need some help with DAX please. I need to count [Number of Active Awards] within a financial period. Then slice this measure by any dimension in the model, not only dates. Here's part ...
- Anonymous8 years ago
The pattern you use for solving the "events in progress" requires that you don't have any active relationship with the date table.
If you inactivate the second relationship between Awards and Dates and then use this measure it will give you the active awards within the min/max dates.
Total Active Awards = VAR MaxPeriod = MAX( dates[Cal Date] ) VAR MinPeriod = MIN( dates[Cal Date] ) RETURN CALCULATE( COUNTROWS( awards ), FILTER ( awards,
awards[Award Start Date] <= MaxPeriod && awards[Award End Date] >= MinPeriod ) )There are several good articles written on the subject of "events in progress".
Br,
Magnus
v-chuncz-msft
8 years agoCommunity Support
Anonymous
8 years agoNot applicable
v-chuncz-msft, thank you. This function doesn't work either, gives me lesser records than expected.
I need ALL records from table 'awards' where awards[Award Start Date] <= MaxPeriodDate && awards[Awards End Date] >= MinPeriodDate. Then I need to be able to slice this number by other dimensions, not only dates, as per the model I sent in my question.