Google-sheets – Filtering views based on a cell having a value

google sheetsgoogle-sheets-filtergoogle-sheets-query

I am trying to sort out a spreadsheet which has multiple columns in but don't really know where to start!

I am looking to filter the sheet where column C has more than 3 errors for the ID on column B.

Where it finds a result like this I need it to show all of the data, hopefully the screenshot below helps explain what I am trying to do!

Showing how I would like it to respond

Best Answer

This can be done by first locating the IDs with three errors or more, and then filtering the data by those IDs. Try this:

=sort( 
  filter( 
    A2:B, 
    match( 
      A2:A, 
      query( 
        query(A2:B, "select A, count(B) where A is not null group by A", 0), 
        "select Col1 where Col2 >= 3", 
        0 
      ), 
      0 
    ) 
  ), 
  1, true, 2, true 
)