Forum Discussion
OEade
4 years agoFrequent Visitor
Equivalent to COUNTIFS
Hi, Apologies, there has been a few topics created on this but I cannot find an answer that applies to my data set. I'm looking to create a measure that shows the count of a specific spend ty...
Pragati11
4 years agoSuper User
Hi OEade ,
I would suggest writing your DAX something like below: (keep in mind I am just writing it seeing your DAX. Can't test it)
Number of Business Trips =
Var hotelTrips =
CALCULATE(
COUNT(Concur[Employee]),Concur[Expense Type]="Hotel")
)
RETURN
CALCULATE(
COUNT(Concur[Expense Type]),
FILTER(
Concur,
Concur[Expense Type]="Hotel" && hotelTrips>10
)
)
See if this works.
OEade
4 years agoFrequent Visitor
Hi Pragati11
I have tried this also. Where 'Hotel Stays' is:
Hotel Stays = CALCULATE(COUNT(Concur[Employee]),Concur[Expense Type]="Hotel")And No. of Business trips being:
Number of Business Trips = CALCULATE(COUNT(Concur[Employee]),
FILTER(Concur,Concur[Expense Type]="Hotel"
&& [Hotel Stays]>10))
This also gives a blank result.
Many thanks,
- onurbmiguel_4 years agoPower Participant