Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
8 years ago
Solved

Distinc Count depending on filters

Hi all,   I'm stack in a formula and I hope you experts could helps me. I have a table with 1m rows, there is a column, to identify the department, "DepName" which is always informed, then I have ...
  • Anonymous's avatar
    Anonymous
    8 years ago

    Well, its done by the measure:

     

    Measure = IF (ISFILTERED([Column8]);IF(HASONEFILTER([Column8]);VALUES(Table[Column8]);"Multiple Departments");"Nothing selected")

    Explaination: 

    if (some selection on slicer) then

      if (num selections) == 1 then

        return columnNameValueSelected

      else (num selections >1)

        return "Multiple Departments"

    else

      "Nothing selected"

     

    Attach the measure into a Card and use it as Title.

     

    Regards.

     

    --

     

    Javi