Forum Discussion
Quest
4 years agoAdvocate I
Problem with calculating values
There is a calculation I am trying to achieve: The data in my report is something like below: Date Product Type #Subscribed 7/1/2021 A Web 2 7/1/2021 A Desktop 5 7/1/2021 B W...
- 4 years ago
Quest please try this
Measure = CALCULATE ( CALCULATE ( DISTINCTCOUNT ( 'Table'[Product] ), CALCULATETABLE ( 'Table', FILTER ( ADDCOLUMNS ( 'Table', "@count", CALCULATE ( SUM ( 'Table'[#Subscribed] ), ALLEXCEPT ( 'Table', 'Table'[Date], 'Table'[Product] ) ) ), [@count] >= 10 ) ) ), ALLEXCEPT ( 'Table', 'Table'[Date] ) )
smpa01
4 years agoCommunity Champion
Quest please try this
Measure =
CALCULATE (
CALCULATE (
DISTINCTCOUNT ( 'Table'[Product] ),
CALCULATETABLE (
'Table',
FILTER (
ADDCOLUMNS (
'Table',
"@count",
CALCULATE (
SUM ( 'Table'[#Subscribed] ),
ALLEXCEPT ( 'Table', 'Table'[Date], 'Table'[Product] )
)
),
[@count] >= 10
)
)
),
ALLEXCEPT ( 'Table', 'Table'[Date] )
)
- Quest4 years agoAdvocate I
Thanks a lot. This works.