Yatz86
1
Hi all,
Is there a way to apply filter context when using Divide?
I would like a Dax measure to Calculate the Hit Rate%: Sales Transaction / Traffic without Store type: SIS.
The expected result is Hit Rate = 4.2%
Thanks in advance for the assistance !
Data for reference:
data.csv (671 Bytes)
Current table
Desired Result
Regards
Hidayat
BrianJ
2
@Yatz86,
I think this gets you what you’re looking for:
Hit Rate Filtered =
CALCULATE([Hit Rate Divide],
FILTER(Sales, Sales[Store Type] <> "SIS")
)
Full solution file posted below:
eDNA Forum - Hit Rate.pbix (39.4 KB)
Yatz86
4
Thanks @BrianJ for the solution!
Works like a charm!
Nick_M
5
@Yatz86
One thing to remember is use the DIVIDE function and not “/”
@BrianJ
Here’s a situation where we could use KEEPFILTERS:
BrianJ
6
@Nick_M,
Can you please elaborate on that a bit? Still trying to wrap my head around exactly what KEEPFILTERS does and the benefit of using it here.
Thanks!
Nick_M
7
@BrianJ
Could you possibly start a new thread? I’ll be sure to answer and throw in some screenshots, but I dont want to clutter up this thread