subqueries removed