statement.setString(1, columnName);
statement.setString(2, value);
statement.setInt(3, sessionID);
if (statement.executeUpdate() == 0) {
logger.error("Cannot find session with ID " + sessionID + " to update " + columnName);
throw new DBException("Cannot find session with ID " + sessionID + " to update " + columnName);
}
statement.close();
} catch (SQLException e) {
logger.error("Cannot update session with ID " + sessionID + " to update " + columnName);
throw new DBException("Cannot update session with ID " + sessionID + " to update " + columnName, e);
}
}