Forum Discussion
Extract unique values from a table into another table
Hello Everyone,
I'm trying to extract the unique values onto a calculated table but seems doestn work my DAX? I was using count function but doest work as it's taken every value and also I need summarize those values, means, the table B below should be the final table.
I have Table A and I need to get table B by extracting the info from table A to table B taking into account only unique values of the invoice column
Table A
| Invoice | Actual | Standard |
| A221 | 20 | 50 |
| A221 | 50 | 30 |
| A221 | 10 | 40 |
| B334 | 45 | 10 |
| B334 | 50 | 40 |
| B3453 | 90 | 10 |
Table B
| Invoice | Actual | Standard |
| A221 | 80 | 120 |
| B334 | 95 | 50 |
| B3453 | 90 | 10 |
Thank you very much!
the following will return a table you want:
Summary Table = SUMMARIZECOLUMNS( 'Table'[Invoice], "Actual Total", SUM('Table'[Actual]), "Standard Total", SUM('Table'[Standard]) )
3 Replies
- edhansCommunity Champion
the following will return a table you want:
Summary Table = SUMMARIZECOLUMNS( 'Table'[Invoice], "Actual Total", SUM('Table'[Actual]), "Standard Total", SUM('Table'[Standard]) )- manuelfigueiraHelper II
Hi Edhans,
This works perfectly well! Thanks a lot!! You're a genius
Enjoy your day!
- edhansCommunity Champion
manuelfigueira wrote:You're a genius
Ha! No.
Coincidenally earlier this week I was working on a similar project and it took me about an hour to get a measure working right for me, and one of the components was a similar use of the SUMMARIZECOLUMNS() function. If you'd have asked last week, I might not have been the guy to answer. 😁
Glad your project is moving forward.