@Override
    public void setCurrentDatabase(String db, boolean check) throws SQLException {
        ensureOpen();

        if (db == null || db.isEmpty()) {
            throw new SQLException("Non-empty database name is required", SqlExceptionUtils.SQL_STATE_INVALID_SCHEMA);
        } else {
            clientRequest.use(db);
            if (check) {
                try (ClickHouseResponse response = clientRequest.query("select 1").executeAndWait()) {
                    database = db;
                } catch (ClickHouseException e) {
                    throw SqlExceptionUtils.handle(e);
                } finally {
                    if (!db.equals(database)) {
                        clientRequest.use(database);
                    }
                }
            } else {
                database = db;
            }
        }
    }
Checks if a feature can be supported or not.

@param feature non-empty feature name
@param silent  whether to show warning in log or throw unsupported exception
@throws SQLException when the feature is not supported and silent is
                     {@code false}
clickhouse-jdbc/src/main/java/com/clickhouse/jdbc/internal/ClickHouseConnectionImpl.java