[SPARK-22252][SQL][FOLLOWUP] Command should not be a LeafNode
## What changes were proposed in this pull request? This is a minor folllowup of #19474 . #19474 partially reverted #18064 but accidentally introduced a behavior change. `Command` extended `LogicalPlan` before #18064 , but #19474 made it extend `LeafNode`. This is an internal behavior change as now all `Command` subclasses can't define children, and they have to implement `computeStatistic` method. This PR fixes this by making `Command` extend `LogicalPlan` ## How was this patch tested? N/A Author: Wenchen Fan <wenchen@databricks.com> Closes #19493 from cloud-fan/minor.
This commit is contained in:
parent
6412ea1759
commit
3823dc88d3
|
@ -24,6 +24,7 @@ import org.apache.spark.sql.catalyst.expressions.Attribute
|
|||
* commands can be used by parsers to represent DDL operations. Commands, unlike queries, are
|
||||
* eagerly executed.
|
||||
*/
|
||||
trait Command extends LeafNode {
|
||||
trait Command extends LogicalPlan {
|
||||
override def output: Seq[Attribute] = Seq.empty
|
||||
override def children: Seq[LogicalPlan] = Seq.empty
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue