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

Filter question

Sorry if it is a dumb question but i have 3 columns, A , B and C, A row sometimes are empty and B rows sometimes are empty too, I want to filter in this way if A and B are both empty the row will not appear, but i dont know how.
1 ACCEPTED SOLUTION
v-alq-msft
Community Support
Community Support

Hi, @Anonymous 


Based on your description, I created data to reproduce your scenario.
Table:
c1.png

 

If you want a filtered table visual to display the result, you may create a measure as below.

Visual control = 
IF(
    OR(
      SELECTEDVALUE('Table'[A])<>BLANK(),
      SELECTEDVALUE('Table'[B])<>BLANK()
    ),
    1,0
)

 

Then you need to put the measure in the visual level filter to display the result.

c4.png

 

If you want to create a new table, you may create a calculated table with the following formula.

New Table = 
FILTER(
    'Table',
    OR(
        'Table'[A]<>BLANK(),
        'Table'[B]<>BLANK()
    )
)

 

Result:

c3.png

 

Best Regards

Allan

 

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

2 REPLIES 2
v-alq-msft
Community Support
Community Support

Hi, @Anonymous 


Based on your description, I created data to reproduce your scenario.
Table:
c1.png

 

If you want a filtered table visual to display the result, you may create a measure as below.

Visual control = 
IF(
    OR(
      SELECTEDVALUE('Table'[A])<>BLANK(),
      SELECTEDVALUE('Table'[B])<>BLANK()
    ),
    1,0
)

 

Then you need to put the measure in the visual level filter to display the result.

c4.png

 

If you want to create a new table, you may create a calculated table with the following formula.

New Table = 
FILTER(
    'Table',
    OR(
        'Table'[A]<>BLANK(),
        'Table'[B]<>BLANK()
    )
)

 

Result:

c3.png

 

Best Regards

Allan

 

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

az38
Community Champion
Community Champion

Hi @Anonymous 

try to create a new Table like

New Table = 
FILTER(Table,
NOT(ISBLANK(Table[Column A])) || NOT(ISBLANK(Table[Column B]))
)

do not hesitate to give a kudo to useful posts and mark solutions as solution
LinkedIn

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.