Forum Discussion

bhelp2021's avatar
bhelp2021
Frequent Visitor
5 years ago
Solved

Power BI Count criteria by Unique ID

Hello,

 

I need help finding an expression for a table.

 

I have two tables, one of the unique customer IDs, one of product information including products assigned to a customer id and its manufacturer.

 

I need to find a way to count how many times a specific manufacturer appears in the product list by customer id.

 

The current formula i have that incorrectly results in a count of how many times the manu. appears:

 

Sum of Manu Prod= Countrows(FILTER('Prod list',[Manufacturer]="MANU01"))

 

I understand this is incorrect but I cannot find an additonal expression to count those appearances by the unique code/customer ID code.

 

Thank you,

bhelp

  • embarrasingly easy solution- Sum of Manu Prod = Calculate(Count('Prod List'[MANU],'Prod list'[MANU]="MANU01")

1 Reply

  • bhelp2021's avatar
    bhelp2021
    Frequent Visitor

    embarrasingly easy solution- Sum of Manu Prod = Calculate(Count('Prod List'[MANU],'Prod list'[MANU]="MANU01")