Forum Discussion
Add All Columns Except One
- 6 years ago
Since new columns will be added all the time, you don't have a true table, but a Pivoted data set. Start by UnPiviotOtherColumns. This will take ALL Other Columns but the one(s) specified and convert them into 'Attribute' (Column Name) and 'Value' (Number Value previously in each column).
Once done, you can create a simple Table of 'Name' and SUM 'Value' to sum ALL columns other than Name even if the raw input changes. *** I couldn't get this working testing with .csv files, but I think that was because of 'type' of the new columns wasn't being defined. I hope with your real data source you might have better luck... ***
= Table.UnpivotOtherColumns(#"Changed Type", {" Name"}, "Attribute", "Value")
1001 - Project 699 | 1000 - LOH - P2 | Name
470 11220 Anchors
1794 10201 Levelling
1794 10201 Basesq
1427 4444 GratePlatforms
736 2255 Modules
367 1161 Pinwheels
1136 990 Exteriorpanel
84 110 Crashbarrier
8 4 Aircraftcable
4 0 MP
31 0 Atticcharge
9 0 Workstation
The first N columns (1001,1000, so on) are project task totals that are required per every job (name)
I need to display the sum of all jobs. Or keep a blank table until they select that specific job which is tough because I cannot make column names part of a slicer (Making a bullet chart. Task completed data is in another table.)
Hope that makes sense.
Since new columns will be added all the time, you don't have a true table, but a Pivoted data set. Start by UnPiviotOtherColumns. This will take ALL Other Columns but the one(s) specified and convert them into 'Attribute' (Column Name) and 'Value' (Number Value previously in each column).
Once done, you can create a simple Table of 'Name' and SUM 'Value' to sum ALL columns other than Name even if the raw input changes. *** I couldn't get this working testing with .csv files, but I think that was because of 'type' of the new columns wasn't being defined. I hope with your real data source you might have better luck... ***
= Table.UnpivotOtherColumns(#"Changed Type", {" Name"}, "Attribute", "Value")
- KassemEl6 years agoFrequent Visitor
Thanks, That seems to have worked 🙂