Forum Discussion

hjansen1976's avatar
hjansen1976
New Member
4 years ago
Solved

calculate CO2

Morning, 

 

Maybe one of you experts could help me out with the following 

 

I have  the following table and would like to calculate the following

Table: 

Field0    field 1   field 2 field 3

1             xyz        200     1.000

2             xyz        300     1.000     

3             xxx        400        500

4             yyy       200        200

5             yyy       100        200

6             abc       150       300

7             bbb      150       300

 

The derised outcome/matrix: 

        field 1     field3

        xyz         1000

        xxx          500

        yyy          200

        abc         300

        bbb        300

Total              2300

So only show field 1 the unique values ( so no doubles) and field 3 the value that belongs to that unique value. And very important a total field for field 3. 

 

Your help is greatly appreciated! 

 

 

  • Hi hjansen1976 ,

     

    You can create a new table with below code:-

     

    Table 2 = SUMMARIZE('Table','Table'[field 1],'Table'[field 3])

     

    Output:-

     

    Thanks,

    Samarth

2 Replies

  • Samarth_18's avatar
    Samarth_18
    Community Champion

    Hi hjansen1976 ,

     

    You can create a new table with below code:-

     

    Table 2 = SUMMARIZE('Table','Table'[field 1],'Table'[field 3])

     

    Output:-

     

    Thanks,

    Samarth