conn.createStatement().execute("ALTER TABLE edge DROP COLUMN edge_license_key;");//NOSONAR, ignoring because method used to execute thingsboard database upgrade script
conn.createStatement().execute("ALTER TABLE edge DROP COLUMN cloud_endpoint;");//NOSONAR, ignoring because method used to execute thingsboard database upgrade script
}catch(Exceptionignored){
}
log.info("Updating schema settings...");
conn.createStatement().execute("UPDATE tb_schema_settings SET schema_version = 3003004;");
log.info("Schema updated.");
}catch(Exceptione){
log.error("Failed updating schema!!!",e);
}
break;
default:
thrownewRuntimeException("Unable to upgrade SQL database, unsupported fromVersion: "+fromVersion);