Skip to content

Commit

Permalink
Fix show keys from support external catalog
Browse files Browse the repository at this point in the history
Signed-off-by: Astralidea <[email protected]>
  • Loading branch information
Astralidea committed Nov 20, 2024
1 parent 406dc4d commit b52df99
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion fe/fe-core/src/main/java/com/starrocks/qe/ShowExecutor.java
Original file line number Diff line number Diff line change
Expand Up @@ -2159,7 +2159,11 @@ public ShowResultSet visitShowDynamicPartitionStatement(ShowDynamicPartitionStmt
@Override
public ShowResultSet visitShowIndexStatement(ShowIndexStmt statement, ConnectContext context) {
List<List<String>> rows = Lists.newArrayList();
Database db = context.getGlobalStateMgr().getDb(statement.getDbName());
String catalogName = statement.getTableName().getCatalog();
if (catalogName == null) {
catalogName = context.getCurrentCatalog();
}
Database db = GlobalStateMgr.getCurrentState().getMetadataMgr().getDb(catalogName, statement.getDbName());
MetaUtils.checkDbNullAndReport(db, statement.getDbName());
Table table = MetaUtils.getSessionAwareTable(context, db, statement.getTableName());
if (table == null) {
Expand Down

0 comments on commit b52df99

Please sign in to comment.