Changed update constructor, important when we are rewriting queries.