Fixed db upgrade bug: do vnc password encryption only for non-removed vms

This commit is contained in:
Alena Prokharchyk 2012-04-21 22:29:12 -07:00
parent 766e892b5b
commit dc07f37ee4
1 changed files with 1 additions and 1 deletions

View File

@ -575,7 +575,7 @@ public class Upgrade2214to30 implements DbUpgrade {
PreparedStatement pstmt = null;
ResultSet rs = null;
try {
pstmt = conn.prepareStatement("select id, vnc_password from `cloud`.`vm_instance`");
pstmt = conn.prepareStatement("select id, vnc_password from `cloud`.`vm_instance` where removed is null");
rs = pstmt.executeQuery();
while (rs.next()) {
long id = rs.getLong(1);