Forum Discussion
Avoid duplicates doing the calculations
Hi,
Especially if all your columns are identical, I think the best options is not to go into complicated DAX but just to remove duplicates using Power Query.
In case using Power Query is not an option, for example you're working with a Direct Query, Semantic model...
1/ You should consider why duplicates are there... since it is not "normal" to have duplicates in the source. So, is it possible to clean the source ?
2/ If not possible to clean the source... Why not building a table with DAX (CALCULATETABLE...) without the duplicates (VALUES, DISTINCT...) and then use this table to do your calculation with simple SUM ?
As far as I am concerned I do not like to work with a source with duplicates, it might be the source of so many troubles, so the best option, would be to clean the source at whatever level (source itself, Power Query, DAX) and then work with clean data.
Hope it helps and it is only my wiew of a situation I do not deeply know