Power BI is turning 10! Tune in for a special live episode on July 24 with behind-the-scenes stories, product evolution highlights, and a sneak peek at what’s in store for the future.
Save the dateEnhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.
I have a customer who has a delivery time that is different from the rest of the other customers, for this customer the time is <= 9 while for the rest the time is <= 8
How do I only count customer times for UNBCES when the delivery time is <=9 at the same time I filter the data of other customers which is <=8
My attempt was first to count the values of the UNBCES client and then take these values and filter again the other clients that have a shorter time, which is <=8, but it didn't work
UNBCES_CLIENT count
UNBCES_CLIENT =
var UNBCES =
CALCULATE(
COUNTROWS(fcriticalDemands),
FILTER(
fcriticalDemands,
fcriticalDemands[CLIENT]="UN-BC" &&
fcriticalDemands[deliveryTime]<=9))
return UNBCES
UNBCES_CLIENT and trying to count the rest of the clients
CLIENTS =
var CLIENT=
CALCULATE(
Leadtime[UNBCES_CLIENT],
FILTER(
fcriticalDemands,
fcriticalDemands[deliveryTime]<=8))
return CLIENT
can you share a sample data and let us know how do you like to show the result?
BTW, if you want to count with different values, try this:
Count_CLIENT =
Vat _Time = if(fcriticalDemands[CLIENT]="UN-BC",9,8)
var _Count=
CALCULATE(
COUNTROWS(fcriticalDemands),
FILTER(
fcriticalDemands,
fcriticalDemands[deliveryTime]<=_Time))
return
_Count
If this post helps, please consider accepting it as the solution to help the other members find it more quickly.
Appreciate your Kudos!!
I want to show something like this, but I have to calculate it differently for the UN-BC client and for the others it's the same thing
The other colors refer to other time calculations, the green value is what we think of the ideal time, which for the un-bc client is <=9
Check out the July 2025 Power BI update to learn about new features.
User | Count |
---|---|
22 | |
7 | |
6 | |
6 | |
6 |
User | Count |
---|---|
27 | |
10 | |
10 | |
9 | |
6 |