diff options
author | scwf <wangfei1@huawei.com> | 2015-05-17 15:17:11 +0800 |
---|---|---|
committer | Cheng Lian <lian@databricks.com> | 2015-05-17 15:17:11 +0800 |
commit | edf09ea1bd4bf7692e0085ad9c70cb1bfc8d06d8 (patch) | |
tree | 2f2625d379f0c8a1e37fce84023808f5bd1af7e2 /sql/catalyst | |
parent | 1a7b9ce80bb5649796dda48d6a6d662a2809d0ef (diff) | |
download | spark-edf09ea1bd4bf7692e0085ad9c70cb1bfc8d06d8.tar.gz spark-edf09ea1bd4bf7692e0085ad9c70cb1bfc8d06d8.tar.bz2 spark-edf09ea1bd4bf7692e0085ad9c70cb1bfc8d06d8.zip |
[SQL] [MINOR] Skip unresolved expression for InConversion
Author: scwf <wangfei1@huawei.com>
Closes #6145 from scwf/InConversion and squashes the following commits:
5c8ac6b [scwf] minir fix for InConversion
Diffstat (limited to 'sql/catalyst')
-rw-r--r-- | sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/analysis/HiveTypeCoercion.scala | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/analysis/HiveTypeCoercion.scala b/sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/analysis/HiveTypeCoercion.scala index fe0d3f2997..b45b17d856 100644 --- a/sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/analysis/HiveTypeCoercion.scala +++ b/sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/analysis/HiveTypeCoercion.scala @@ -296,6 +296,9 @@ trait HiveTypeCoercion { */ object InConversion extends Rule[LogicalPlan] { def apply(plan: LogicalPlan): LogicalPlan = plan transformAllExpressions { + // Skip nodes who's children have not been resolved yet. + case e if !e.childrenResolved => e + case i @ In(a, b) if b.exists(_.dataType != a.dataType) => i.makeCopy(Array(a, b.map(Cast(_, a.dataType)))) } |