class SQL implements Runnable {

    @Override
    public void run() {
        if (allParams == null) {
            outputStream.print("No SQL input, please enter a valid SQL command");
            return;
        }
        if (dbManager == null) {
            if (State.getCurrentStorageType() != DataStorageType.PUREDB) {
                outputStream.print("Currently not connected to the database, cannot execute SQL");
                return;
            } else {
                dbManager = DBManager.getInstance();
            }
        }

        String sql = String.join(" ", allParams);

        //Standard implementation with normal connection
        try (Connection connection = dbManager.getStandardSqlConnection()) {
            connection.setReadOnly(true);

            executeQuery(connection, sql, outputStream);
        } catch (SQLException e) {
            LOGGER.log(Level.WARNING, e.getMessage(), e);
            outputStream.print("Couldn't connect to the database");
        }
    }

    public  SQL(DBManager dbManager);
    public  SQL(PrintStream outputStream);
    public  SQL(DBManager dbManager, PrintStream outputStream);
    public  SQL();

}