Forum Discussion
Anonymous
6 years agoNot applicable
how to Count distinct date value by Name ?
hello, How to calculate distinct date value by Name? want dax for it. I want this column in power bi ( countdistinct of date by Name). Plus then sum all the values of name single time. ...
- 6 years ago
Anonymous
as you use a date slicer you could try this
Measure = var _minDate = CALCULATE(MIN('Table'[Date]),ALLSELECTED('Table')) var _maxDate = CALCULATE(MAX('Table'[Date]),ALLSELECTED('Table')) return SUMX(SUMMARIZE('Table', 'Table'[Name], "DistinctDates", CALCULATE(DISTINCTCOUNT('Table'[Date]), ALLEXCEPT('Table','Table'[Name]), DATESBETWEEN('Table'[Date], _minDate, _maxDate))),[DistinctDates] )to notificate me about new questions please mark me with @ symbol
az38
Community Champion
6 years agoHi Anonymous
try
Measure = CALCULATE(DISTINCTCOUNT('Table'[Date]), ALLEXCEPT('Table', 'Table'[Name]) )Anonymous
6 years agoNot applicable
hello
this is not working.
what I want is to add all the value of distinct dates count by the name.
example
- distinct count of dates by name .
this is what I want and then sum all the distinctcount of date by name . (Single time)
- az386 years ago
Community Champion
Anonymous
see my second post. doesn't it ok?
- Anonymous6 years agoNot applicable
No, it is adding all the values. not working.
- az386 years ago
Community Champion
Anonymous
i think its completely what you need.
Name Date A 01.01.2020 A 01.01.2020 A 02.01.2020 A 03.01.2020 A 03.01.2020 A 04.01.2020 B 05.01.2020 B 06.01.2020 B 06.01.2020