I have a Google Sheets and want to query in a column called BY. This is failing:
BY
=query(Data!A:GC, \"select BY where BG = \'completed\'\")
Please try backquotes - eg:
=query(Data!A:GC, "select `BY` where BG = 'completed'")