Forum Discussion
Using Dax to remove duplicates before summing up a column
- 9 years ago
You could try and remove duplicates via the Query Editor (which has an excellent function for removing duplicates)
Or in DAX you could create a summary table with just the lines you need
Summary Invoice Table = SUMMARIZECOLUMNS( 'Invoice'[InvoiceNumber], --- Columns --- "AmountDueAUD",MAX('Invoice'[AmountDueAUD]) )
You could try and remove duplicates via the Query Editor (which has an excellent function for removing duplicates)
Or in DAX you could create a summary table with just the lines you need
Summary Invoice Table = SUMMARIZECOLUMNS(
'Invoice'[InvoiceNumber],
--- Columns ---
"AmountDueAUD",MAX('Invoice'[AmountDueAUD])
)Thanks Phil_Seamark. This worked for me.
I wanted to do it without having to create a new table and also I couldn't do it via Query Editor because there were other charts that relied on the duplicates.
Please let me know if you come across something that solved this problem without having to create a new summary table.
- Phil_Seamark9 years agoMicrosoft Employee
Hi bjoshi,
It probably is possible to do as a measure over your original table, but it's probably not good data modelling to have the same number on repeating lines that shouldn't be there in the first place.