Xiao Li created SPARK-16368:
-------------------------------
Summary: Strange Errors When Creating View With Unmatched Column
Num
Key: SPARK-16368
URL: https://issues.apache.org/jira/browse/SPARK-16368
Project: Spark
Issue Type: Bug
Components: SQL
Affects Versions: 2.0.0
Reporter: Xiao Li
When creating a view, a common user error is the number of columns produced by
the SELECT clause does not match the number of column names specified by CREATE
VIEW.
For example, given Table {{t1}} only has 3 columns
{noformat}
create view v1(col2, col4, col3, col5) as select * from t1
{noformat}
Currently, Spark SQL reports the following error:
{noformat}
requirement failed
java.lang.IllegalArgumentException: requirement failed
at scala.Predef$.require(Predef.scala:212)
at
org.apache.spark.sql.execution.command.CreateViewCommand.run(views.scala:90)
{noformat}
This error is very confusing.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]