diff --git a/infra/database/type/opengauss/src/main/java/org/apache/shardingsphere/infra/database/opengauss/metadata/data/loader/OpenGaussMetaDataLoader.java b/infra/database/type/opengauss/src/main/java/org/apache/shardingsphere/infra/database/opengauss/metadata/data/loader/OpenGaussMetaDataLoader.java index f3501c4647395..ac2c19488946d 100644 --- a/infra/database/type/opengauss/src/main/java/org/apache/shardingsphere/infra/database/opengauss/metadata/data/loader/OpenGaussMetaDataLoader.java +++ b/infra/database/type/opengauss/src/main/java/org/apache/shardingsphere/infra/database/opengauss/metadata/data/loader/OpenGaussMetaDataLoader.java @@ -101,7 +101,7 @@ private Map> loadIndexMetaDataMap(final String indexName = resultSet.getString("index_name"); boolean isUnique = resultSet.getBoolean("is_unique"); Collection indexMetaDatas = result.getOrDefault(schemaName, LinkedHashMultimap.create()).get(tableName); - if (null == indexMetaDatas || indexMetaDatas.isEmpty()) { + if (indexMetaDatas.isEmpty()) { continue; } Optional indexMetaData = indexMetaDatas.stream().filter(each -> each.getName().equals(indexName)).findFirst();