morningman commented on a change in pull request #5880:
URL: https://github.com/apache/incubator-doris/pull/5880#discussion_r640546507



##########
File path: 
fe/fe-core/src/main/java/org/apache/doris/transaction/TransactionState.java
##########
@@ -526,11 +530,23 @@ public synchronized void addTableIndexes(OlapTable table) 
{
 
     @Override
     public String toString() {
+        Database db = Catalog.getCurrentCatalog().getDb(dbId);
+        String dbName = null;
+        String tableNameList = null;
+        if (db != null) {
+           dbName = db.getFullName();
+           tableNameList = tableIdList.stream()
+                   .map(db::getTable)
+                   .filter(Objects::nonNull)
+                   .map(Table::getName).collect(Collectors.joining(","));
+        }

Review comment:
       We have add `show database id` stmt to find database name from database 
id.
   So there is no need to print database name here.
   And a database may have thousands of tables, so print all table here may be 
disaster.




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
[email protected]



---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to