Google Sheets: How do I filter view two columns OR instead of AND

Rage Kage picture Rage Kage · Nov 9, 2017 · Viewed 14.1k times · Source

In Google Sheets, I want to filter view my results so only rows with an "x" in column D AND/OR column E are shown. If I filter to show the columns with an "x" in them, it will only show rows with an "x" in column D AND column E.

How do I make it do AND/OR? When I click the filter button in the column it just asks me to select which entries I want to show.

Screenshot

Answer

Ed Nelson picture Ed Nelson · Nov 10, 2017

Click on column D. On the menu click Data. Select Filter. Then click the filter icon. Select Filter by condition. Click the down arrow on none and scroll down to Custom formula is. Select and enter =or(D:D="x",E:E="x") in value or formula.Click OK. Or, create sheet2 and in A1 enter =FILTER(Sheet1!A:E,(Sheet1!D:D="x")+(Sheet1!E:E="x")). Adjust the columns as needed.