diff --git a/CHANGELOG.md b/CHANGELOG.md index 920e04b162..2ca5b23622 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,6 +5,7 @@ Please mark all change in change log and use the issue from GitHub # Milvus 0.7.0 (TBD) ## Bug +- \#744 - Don't return partition table for show_tables ## Feature - \#343 - Add Opentracing diff --git a/core/src/db/DBImpl.cpp b/core/src/db/DBImpl.cpp index 738f080963..1e51368fde 100644 --- a/core/src/db/DBImpl.cpp +++ b/core/src/db/DBImpl.cpp @@ -173,7 +173,18 @@ DBImpl::AllTables(std::vector& table_schema_array) { return SHUTDOWN_ERROR; } - return meta_ptr_->AllTables(table_schema_array); + std::vector all_tables; + auto status = meta_ptr_->AllTables(all_tables); + + // only return real tables, dont return partition tables + table_schema_array.clear(); + for (auto& schema : all_tables) { + if (schema.owner_table_.empty()) { + table_schema_array.push_back(schema); + } + } + + return status; } Status