added support for update queries