You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@spark.apache.org by GitBox <gi...@apache.org> on 2021/03/01 05:47:31 UTC

[GitHub] [spark] cloud-fan commented on a change in pull request #31675: [SPARK-34560][SQL] Generate unique output attributes in the `SHOW TABLES` logical node

cloud-fan commented on a change in pull request #31675:
URL: https://github.com/apache/spark/pull/31675#discussion_r584459287



##########
File path: sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/plans/logical/v2Commands.scala
##########
@@ -491,13 +491,10 @@ case class RenameTable(
  */
 case class ShowTables(
     namespace: LogicalPlan,
-    pattern: Option[String],
-    override val output: Seq[Attribute] = ShowTables.OUTPUT) extends Command {
+    pattern: Option[String]) extends Command {
   override def children: Seq[LogicalPlan] = Seq(namespace)
-}
 
-object ShowTables {
-  val OUTPUT = Seq(

Review comment:
       Can we simply use `def` here? Then every `ShowTables` node will get a fresh output, while the output is super stable within the corresponding `ShowTables` node.




----------------------------------------------------------------
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:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org