Forum Discussion
Andrew_na_lang
Helper V
4 years agoCount and percentage
Hi Power bi Family, I am stuck here. I have done this in the past but not sure why it wasn't working now. I basically need to have a count of the customers who have "BLANK" CountOfOrdersAfterC...
- 4 years ago
Try something like the following:
NumberBlank = VAR CustomersWithBlanks = FILTER ( VALUES( CustomerTable[CustomerName] ), ISBLANK([CountOfOrderAfterClaim]) ) RETURN COUNTROWS( CustomersWithBlanks )I suspect you can do something more efficient by testing directly but would need to see your data model.
bcdobbs
Community Champion
4 years agoIs CountOfOrdersAfterClaim a calculated column or measure?
- Andrew_na_lang4 years ago
Helper V
bcdobbs It is a measure.
CountOfOrderAfterClaim = CALCULATE(COUNTROWS(Orders), FILTER(Orders, Orders[Count_of_orders_after_Last_claim]= "1" && Orders[order_status_description] = "Order Completed" ))- bcdobbs4 years ago
Community Champion
Ok and that that visual... what are you grouping by? Eg is it one line per customer? Do you have a customer dimension table with customer Ids?
- Andrew_na_lang4 years ago
Helper V
bcdobbs Yes, it is one line per customer.
It is grouped by customer name.