Fix update query expression for branches/versions.