Forum Discussion
how to Sum between two columns dynamically
Hi UrAvgWally
Yes possible but depends on the your model, existing relationships, current filter context. I can only guess that you have a matrix visual were you have the periods on the row or on the columns and a measure (or summarized column) in the values. I don't know if they belong to the same table? If you have a Date table? Any relationships? Any of my assumptions is correct?
- UrAvgWally4 years agoHelper I
Hiya! The above column's are in a raw data file, no filters or existing relationships. I will try explaining my dataset.
So I want to create a table which one column is the Funder and the other would be the sum , sum being COWD project to date + Period 3 + Period 4 + Period 5. I would like to have an Option to determine what the current period is , and what the base line period is and sum everything in between. So hypothetically if I am in Period 5 atm, I want to be able to sum Period 4 and Period 5. .. If I am in Period 8 and I chose my baseline period to be Period 6, I want to be able to add Period 7 and Period 8 and Cowd Project to date.
So it would be nbice to be able to chose my current period and baseline period and add dynamically like that.- tamerj14 years agoCommunity Champion
Hi UrAvgWally
In order to do that the periods have to attributes in a one column [Period]. In order to do that you need to unpivot all the period columns using power query. It is a one click operation >> select the columns that need to be unpivoted, right click and select "Unpivot columns". But PLEASE BECAREFUL if you have large data, your file might crash. So please before doing anything PLEASE KEEP A BACKUP copy of your file. Once you do that, please let me know in order to guide you through the next steps.