dongjoon-hyun commented on a change in pull request #30529:
URL: https://github.com/apache/spark/pull/30529#discussion_r532258529



##########
File path: 
sql/core/src/main/scala/org/apache/spark/sql/execution/command/tables.scala
##########
@@ -878,12 +878,17 @@ case class ShowTablesCommand(
       //
       // Note: tableIdentifierPattern should be non-empty, otherwise a 
[[ParseException]]
       // should have been thrown by the sql parser.
-      val tableIdent = TableIdentifier(tableIdentifierPattern.get, Some(db))
-      val table = catalog.getTableMetadata(tableIdent).identifier
-      val partition = catalog.getPartition(tableIdent, partitionSpec.get)
-      val database = table.database.getOrElse("")
-      val tableName = table.table
-      val isTemp = catalog.isTemporaryTable(table)
+      val table = 
catalog.getTableMetadata(TableIdentifier(tableIdentifierPattern.get, Some(db)))
+      val tableIdent = table.identifier

Review comment:
       Is there a reason you change from
   ```scala
   val tableIdent = TableIdentifier(tableIdentifierPattern.get, Some(db))
   val table = catalog.getTableMetadata(tableIdent).identifier
   ```
   to 
   ```scala
   val table = 
catalog.getTableMetadata(TableIdentifier(tableIdentifierPattern.get, Some(db)))
   val tableIdent = table.identifier
   ```
   




----------------------------------------------------------------
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