Forum Discussion

ChrisAZ's avatar
ChrisAZ
Helper V
1 year ago
Solved

Adding a Total column in a matrix

Hello,

 

So I am trying to add total column at the end of my matrix that will provide a total by Vehicle that Sums Part cost, Labor cost, and Fuel cost. Fuel costs are not populated yet but will be soon. The issue I am having is that I can create a column if I want to do it directly under the Part, Labor, or Fuel data sources, but since this is for all 3 items, I would prefer to do it in a way that does not require it to live in just one of those datasets. Is that possible?

 

  • It is a pretty common scenario, not odd. Or you can have a dummy table and add measure in that table, and it is also a common practice. 

8 Replies

  • ChrisAZ sorry it is not clear what you are trying to achieve. Could you please provide a little more detail? Thanks!

  • ChrisAZ your request is not clear...
    but u could try creating a measure that calculates the sum of "Part_cost", "Labour_cost" and "Fuel_cost" respectively. Then finally create another measure Total cost = Part_Cost + Labour_Cost + Fuel_Cost

    • ChrisAZ's avatar
      ChrisAZ
      Helper V

      I want a column in the space indicated that is totalling the columns to the left for each vehicle. I know I can create a measure in one of those existing data sets, but I am wondering if there is a way to do it without having to pick one of those data sources to apply it to?

  • ChrisAZ, it is still a bit confusing. Do you want this empty column to be calculated dynamically?

    • ChrisAZ's avatar
      ChrisAZ
      Helper V

      Sorry, not sure how I could be more clear on it. I want it to calculate a total column to the right of the others to total up what is in the row all the way down for each vehicle, I just would rather not have the Measure/column have to be stored in one of the many data sets that comprise the other columns.

  • ChrisAZ measures are global to the model, they are not tied with any table. Not sure if that is what you are looking for. 

    • ChrisAZ's avatar
      ChrisAZ
      Helper V

      I think that is what I meant. The fields in this table come from different models, so having a measure sit in one of them seems odd for organization?

      • parry2k's avatar
        parry2k
        Super User

        It is a pretty common scenario, not odd. Or you can have a dummy table and add measure in that table, and it is also a common practice.