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

Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes! Register now.

Reply
Sebastian_N1
Regular Visitor

Slicer showing unselected values

So I have a slicer that filters out employees based on thier supervisor. When i try to exclude a supervisors team, that supervisors team still shows but they are just blank. This issue strted when i input this measure to sum durations. Is there any way I can keep the sum of the durations and have the table only show the actuall values selected? 

 

Heres the formula i used to sum duration:

 

Logged In Time = (VAR TotalSeconds=SUMX('ScorecardRawData',HOUR('ScorecardRawData'[LoggedOnTime])*3600+MINUTE('ScorecardRawData'[LoggedOnTime])*60+SECOND('ScorecardRawData'[LoggedOnTime]))
VAR Days =TRUNC(TotalSeconds/3600/8)
VAR Hors = TRUNC((TotalSeconds-Days*3600*8)/3600)
VAR Mins =TRUNC(MOD(TotalSeconds,3600)/60)
VAR Secs = MOD(TotalSeconds,60)
return IF(Hors<10,"0"&Hors,Hors)&":"&IF(Mins<10,"0"&Mins,Mins)&":"&IF(Secs<10,"0"&Secs,Secs))

 

Here is what my table look slike when i try and filter. The Red values should not be showing up at all because I have not selected those people in my slicer

 

Capture.PNG

2 ACCEPTED SOLUTIONS
BrianMiller
Regular Visitor

You should be able to use the filter on the measure to only show when the measure is greater than zero.  This will eliminate the empty rows.

View solution in original post

v-yuta-msft
Community Support
Community Support

Hi Sebastian_N1,

 

As a general solution, you can add an if condition to wrap your measure like pattern below:

Average of SF% =
IF ( CALCULATE ( aggregation ) <> BLANK (), CALCULATE ( aggregation ) )

Regards,

Jimmy Tao

View solution in original post

3 REPLIES 3
v-yuta-msft
Community Support
Community Support

Hi Sebastian_N1,

 

As a general solution, you can add an if condition to wrap your measure like pattern below:

Average of SF% =
IF ( CALCULATE ( aggregation ) <> BLANK (), CALCULATE ( aggregation ) )

Regards,

Jimmy Tao

BrianMiller
Regular Visitor

You should be able to use the filter on the measure to only show when the measure is greater than zero.  This will eliminate the empty rows.

Greg_Deckler
Community Champion
Community Champion

Please see this post regarding How to Get Your Question Answered Quickly: https://community.powerbi.com/t5/Community-Blog/How-to-Get-Your-Question-Answered-Quickly/ba-p/38490

 

Sample data.



Follow on LinkedIn
@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
DAX For Humans

DAX is easy, CALCULATE makes DAX hard...

Helpful resources

Announcements
September Power BI Update Carousel

Power BI Monthly Update - September 2025

Check out the September 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.

Top Solution Authors
Top Kudoed Authors