Skip to content

Commit 73f2853

Browse files
viiryacloud-fan
authored andcommitted
[SPARK-23979][SQL] MultiAlias should not be a CodegenFallback
## What changes were proposed in this pull request? Just found `MultiAlias` is a `CodegenFallback`. It should not be as looks like `MultiAlias` won't be evaluated. ## How was this patch tested? Existing tests. Author: Liang-Chi Hsieh <viirya@gmail.com> Closes #21065 from viirya/multialias-without-codegenfallback.
1 parent cbb41a0 commit 73f2853

File tree

1 file changed

+2
-2
lines changed
  • sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/analysis

1 file changed

+2
-2
lines changed

sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/analysis/unresolved.scala

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ import org.apache.spark.sql.AnalysisException
2121
import org.apache.spark.sql.catalyst.{FunctionIdentifier, InternalRow, TableIdentifier}
2222
import org.apache.spark.sql.catalyst.errors.TreeNodeException
2323
import org.apache.spark.sql.catalyst.expressions._
24-
import org.apache.spark.sql.catalyst.expressions.codegen.{CodegenContext, CodegenFallback, ExprCode}
24+
import org.apache.spark.sql.catalyst.expressions.codegen.{CodegenContext, ExprCode}
2525
import org.apache.spark.sql.catalyst.parser.ParserUtils
2626
import org.apache.spark.sql.catalyst.plans.logical.{LeafNode, LogicalPlan, UnaryNode}
2727
import org.apache.spark.sql.catalyst.trees.TreeNode
@@ -335,7 +335,7 @@ case class UnresolvedRegex(regexPattern: String, table: Option[String], caseSens
335335
* @param names the names to be associated with each output of computing [[child]].
336336
*/
337337
case class MultiAlias(child: Expression, names: Seq[String])
338-
extends UnaryExpression with NamedExpression with CodegenFallback {
338+
extends UnaryExpression with NamedExpression with Unevaluable {
339339

340340
override def name: String = throw new UnresolvedException(this, "name")
341341

0 commit comments

Comments
 (0)