Forum Discussion
Anonymous
7 years agoNot applicable
Help with challenging SUMX calculated columns problem
Hello,
I am trying to do this: for every row in Table1, filter Table1 between the rows StartDate column and StartDate plus 90 days and then within that filtered date range for Table1, sum up all the values in the Revenue column. I was thinking of doing this using a calculated column and using the function SUMX but I am struggling so I was wondering if anyone has any ideas for this problem.
Thanks
Anonymous
You may refer to the DAX below.
Column = VAR d = Table1[StartDate] RETURN SUMX ( FILTER ( Table1, Table1[StartDate] >= d && Table1[StartDate] <= d + 90 ), Table1[Revenue] )
2 Replies
- parry2kSuper User
Anonymous Read this post to get your answer quickly.
https://community.powerbi.com/t5/Community-Blog/How-to-Get-Your-Question-Answered-Quickly/ba-p/38490 - v-chuncz-msftCommunity Support
Anonymous
You may refer to the DAX below.
Column = VAR d = Table1[StartDate] RETURN SUMX ( FILTER ( Table1, Table1[StartDate] >= d && Table1[StartDate] <= d + 90 ), Table1[Revenue] )