Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
abeirne
Helper II
Helper II

Using filter functions on a measure in table

Hi all, I am trying to show the email capture rate of my stores, but the table I am currently using shows all of the employees. I would like to show the email capture rate per store versus per employee. I am thinking maybe an ALL() would work? I have tried all() on the main store # table and columns but did not seem to work. 

Current measure:

Email Capture % =
CALCULATE(
DISTINCTCOUNT(Invoice_[Customer_Email_Address]) / 'Invoice_Detail_'[GC],
ALL(Invoice_)
)

abeirne_0-1652198166874.png

So for store 17, I want the email capture rate to be the same, showing the capture rate for the whole store instead of individually, and so on for the next stores. I have redacted some info. Thank you all for the help. 

1 ACCEPTED SOLUTION
Anonymous
Not applicable

Hi @abeirne ,

 

Are 'Invoice_Detail_' [GC] the same for the same stores?

Please try this formula.

Email Capture % =
CALCULATE (
    DISTINCTCOUNT ( Invoice_[Customer_Email_Address] ),
    FILTER ( ALL ( Invoice_ ), [stores] = SELECTEDVALUE ( stores ) )
)
    / SELECTEDVALUE ( 'Invoice_Detail_'[GC] )

 

Best Regards,

Jay

View solution in original post

3 REPLIES 3
Anonymous
Not applicable

Hi @abeirne ,

 

Are 'Invoice_Detail_' [GC] the same for the same stores?

Please try this formula.

Email Capture % =
CALCULATE (
    DISTINCTCOUNT ( Invoice_[Customer_Email_Address] ),
    FILTER ( ALL ( Invoice_ ), [stores] = SELECTEDVALUE ( stores ) )
)
    / SELECTEDVALUE ( 'Invoice_Detail_'[GC] )

 

Best Regards,

Jay

abeirne
Helper II
Helper II

Yeah I know it was not super clear, sorry for that. I hadn't thought of the allexcept, I will try it. Thank you!

amitchandak
Super User
Super User

@abeirne , Not very clear. Try like

 

Current measure:
Email Capture % =
CALCULATE(
divide(DISTINCTCOUNT(Invoice_[Customer_Email_Address]) , 'Invoice_Detail_'[GC]),
ALLEXCEPT(Invoice_, Invoice_ [Store])
)

Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!

November Power BI Update Carousel

Power BI Monthly Update - November 2025

Check out the November 2025 Power BI update to learn about new features.

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.