Browse Source

SONAR-12689 fix migration failure on oracle

tags/8.1.0.31237
Michal Duda 4 years ago
parent
commit
61cdfa9134

+ 4
- 2
server/sonar-db-migration/src/main/java/org/sonar/server/platform/db/migration/version/v81/PopulateExcludeBranchFromPurgeColumn.java View File

@@ -37,8 +37,10 @@ public class PopulateExcludeBranchFromPurgeColumn extends DataChange {
@Override
public void execute(Context context) throws SQLException {
Long now = system.now();
context.prepareUpsert("update project_branches set exclude_from_purge = true, updated_at = ? where branch_type = 'LONG'")
.setLong(1, now)
context.prepareUpsert("update project_branches set exclude_from_purge = ?, updated_at = ? where branch_type = ?")
.setBoolean(1, true)
.setLong(2, now)
.setString(3, "LONG")
.execute()
.commit();
}

Loading…
Cancel
Save