Forum Discussion
Anonymous
4 years agoNot applicable
EXCEPT ALLSELECTED
HI!!!! I have a table with costumers and year, and i have to count the numbers of costumers accordingly the year selected in the slicer, and count the numbers of costumers that less than the year...
- 4 years ago
Hi Anonymous ,
Please try the following measure:
INATIVO = VAR selectyear = SELECTEDVALUE ( costumers[year purchase] ) VAR _count = CALCULATE ( COUNT ( costumers[Costumers] ), FILTER ( ALL ( costumers[year purchase] ), costumers[year purchase] > selectyear ) ) RETURN IF ( selectyear <> BLANK (), _count )If the problem is still not resolved, please provide detailed error information or the expected result you expect. Let me know immediately, looking forward to your reply.
Best Regards,
Winniz
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Samarth_18
4 years agoCommunity Champion
Anonymous You mean you need count of customers for next 3 years of selected year?
Anonymous
4 years agoNot applicable
Yes.
- Samarth_184 years agoCommunity Champion
Anonymous Please try:-
Selected_year = CALCULATE ( COUNT ( costumers[Costumers] ), FILTER ( costumers, costumers[year purchase] > SELECTEDVALUE ( costumers[year] ) && costumers[year purchase] <= SELECTEDVALUE ( costumers[year] ) + 3 ) )- Anonymous4 years agoNot applicable
Srry samarth, bus doesn't worked too.
The result of the count it's like considering only 2020 and 2022.
- Samarth_184 years agoCommunity Champion
Anonymous is it possible for you to share your PBIX file after removing sensitive data? and also the expected output?