yaooqinn commented on a change in pull request #31804:
URL: https://github.com/apache/spark/pull/31804#discussion_r592072172



##########
File path: 
sql/core/src/main/scala/org/apache/spark/sql/catalyst/analysis/ResolveSessionCatalog.scala
##########
@@ -366,13 +366,13 @@ class ResolveSessionCatalog(val catalogManager: 
CatalogManager)
         partitionSpec @ (None | Some(UnresolvedPartitionSpec(_, _))),
         output) =>
       val newOutput = if 
(conf.getConf(SQLConf.LEGACY_KEEP_COMMAND_OUTPUT_SCHEMA)) {
-        assert(output.length == 4)
-        output.head.withName("database") +: output.tail
+        assert(output.length == 5)

Review comment:
       > this should be output.length == 4
   
   indeed, this is true.  `output.head.withName("database") +: output.slice(1, 
4)` will cut the `isView` off




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