String insertQuery = "INSERT INTO emailmessagefolder (MessageID, FolderID) VALUES (?, ?)";
cvdal.setSqlQuery(insertQuery);
cvdal.setInt(1, messageID);
cvdal.setInt(2, newFolderID);
numberMoved = cvdal.executeUpdate();
cvdal.setSqlQueryToNull();
String deleteQuery = "DELETE FROM emailmessagefolder WHERE MessageID = ? AND FolderID = ?";
cvdal.setSqlQuery(deleteQuery);
cvdal.setInt(1, messageID);