pass query to adapter