Google Sheets – List All Records with Certain Criteria

google sheetsgoogle-sheets-query

Help. I just cannot get this going even after 2 hours of searching Google.

I have a Google Spreadsheet that has a "List" sheet and an "Outstanding" sheet. I want to see what's outstanding from a certain contractor from List so I can print it out as a ledger and send it to him. Essentially I need the following:

P is the company name, L is the date paid (if L is empty, they haven't paid)

List * rows where P="Production Company" and L="<empty>"

So I can type a company name into the sheet and it should be able to find all the rows in List that fit the criteria above and list all A:U columns down the page.

Is it possible?

Best Answer

If the desired company name is in A1 I think you may have a use for something like:

=query(List!A:U, "select * where A contains '"&$A1&"' and L is null and P contains 'Production Company' ")