bug 11217: only work on the snapshot whose state is "backedup" and is not removed

status 11217: resolved fixed
This commit is contained in:
Edison Su 2011-08-29 15:23:33 -07:00
parent 367405ac42
commit dbe7cdf4b0
1 changed files with 1 additions and 1 deletions

View File

@ -73,7 +73,7 @@ public class Upgrade229to2210 implements DbUpgrade {
ResultSet rs = null;
long currentSnapshotId = 0;
try {
pstmt = conn.prepareStatement("select id, prev_snap_id from snapshots where sechost_id is NULL and prev_snap_id is not NULL order by id");
pstmt = conn.prepareStatement("select id, prev_snap_id from snapshots where sechost_id is NULL and prev_snap_id is not NULL and status=\"BackedUp\" and removed is NULL order by id");
rs = pstmt.executeQuery();
while (rs.next()) {
long id = rs.getLong(1);