Updates query handling.