improved querying