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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
Anonymous
Not applicable

Want to remove Blank results from a DISTINCT DAX

Hello,

 

I'd be grateful if someone'd shed some light here:

 

When I use measure then I get a row with a Blank value:

 

Team Table =
DISTINCT (
UNION (
SELECTCOLUMNS ( DIA_SAP_ABSENZEN, "Team", DIA_SAP_ABSENZEN[Team] ),
VALUES ( DIA_SAP_FERIENSOLL[Team] )
)
)
 
How can remove the Blank from the results?
1 ACCEPTED SOLUTION
amitchandak
Super User
Super User

@Anonymous , Try like

 

DISTINCT (filter(
UNION (
SELECTCOLUMNS ( DIA_SAP_ABSENZEN, "Team", DIA_SAP_ABSENZEN[Team] ),
VALUES ( DIA_SAP_FERIENSOLL[Team] )
),not(isblank(Team))
) )

View solution in original post

2 REPLIES 2
amitchandak
Super User
Super User

@Anonymous , Try like

 

DISTINCT (filter(
UNION (
SELECTCOLUMNS ( DIA_SAP_ABSENZEN, "Team", DIA_SAP_ABSENZEN[Team] ),
VALUES ( DIA_SAP_FERIENSOLL[Team] )
),not(isblank(Team))
) )

Anonymous
Not applicable

Hi @amitchandak 

 

Thank you very much for your response and suggestion!

 

This is how I applied it, and it works:

 

Team Table =
DISTINCT (FILTER(
UNION (
SELECTCOLUMNS ( DIA_SAP_ABSENZEN, "Team", DIA_SAP_ABSENZEN[Team] ),
VALUES ( DIA_SAP_FERIENSOLL[Team] )
),NOT(ISBLANK([Team])
)))
 
Now, there are no longer Blanks in the table. However, when I use Team in a Slicer, then I can still see Blank as value. I'm worried that this might impact my visuals in a way that I'm not aware of (even if I filter out Blank from the slicer).
 
Do you think it's ok as it is?

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.