Forum Discussion

FatBlackCat30's avatar
FatBlackCat30
Microsoft Employee
5 years ago
Solved

Card Visual to dcount based off two conditions

Hi all,   I have two card visuals showing the distinct count of ID's based off a scenario (No Category Selected & No cusomter Name).  A single ID can have both scenarios, when I filter to scenario ...
  • v-kelly-msft's avatar
    5 years ago

    Hi FatBlackCat30 ,

     

    Create 2 measures as below:

    No Category Selected = CALCULATE(DISTINCTCOUNT('Example Data'[Product]),FILTER(ALL('Example Data'),'Example Data'[Scenario ]="No Category Selected"))
    No Customer Name = CALCULATE(DISTINCTCOUNT('Example Data'[Product]),FILTER(ALL('Example Data'),'Example Data'[Scenario ]="No Customer Name"))

    And you will see:

     

    For the related .pbix file,pls see attached.

     

    Best Regards,
    Kelly

    Did I answer your question? Mark my post as a solution!