Fixed query logs querying