Forum Discussion
Cummulative by Street
- 3 years ago
Hi spandy34 ,
With this measure calculating the number of properties (without cummulation):
# Properties = SUM ( 'Properties by Street'[No of Properties] )this measure calculates the cummulative number of properties by street:
# Properties cummulating by street = VAR _UpToStreet = MAX ( 'Properties by Street'[STREE_NAME] ) RETURN CALCULATE ( [# Properties], 'Properties by Street'[STREE_NAME] <= _UpToStreet )Be aware that the order by which is cummulated is defined by the measure, not by the visual. I.e., if you sort the table by a different column, cummulation is not done top to bottom but still by street name alphabetically ascending. If you want to cummulate differently, you need a different measure.
BR
Martin
Hi spandy34 ,
With this measure calculating the number of properties (without cummulation):
# Properties = SUM ( 'Properties by Street'[No of Properties] )
this measure calculates the cummulative number of properties by street:
# Properties cummulating by street =
VAR _UpToStreet = MAX ( 'Properties by Street'[STREE_NAME] )
RETURN
CALCULATE (
[# Properties],
'Properties by Street'[STREE_NAME] <= _UpToStreet
)
Be aware that the order by which is cummulated is defined by the measure, not by the visual. I.e., if you sort the table by a different column, cummulation is not done top to bottom but still by street name alphabetically ascending. If you want to cummulate differently, you need a different measure.
BR
Martin