You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@spark.apache.org by "Chen Chao (JIRA)" <ji...@apache.org> on 2014/05/23 10:40:01 UTC
[jira] [Created] (SPARK-1913) column pruning problem of Parquet
File
Chen Chao created SPARK-1913:
--------------------------------
Summary: column pruning problem of Parquet File
Key: SPARK-1913
URL: https://issues.apache.org/jira/browse/SPARK-1913
Project: Spark
Issue Type: Bug
Components: SQL
Affects Versions: 1.0.0
Environment: mac os 10.9.2
Reporter: Chen Chao
case class Person(name: String, age: Int)
if we use Parquet file, the following statement will throw a exception says java.lang.IllegalArgumentException: Column age does not exist.
sql("SELECT name FROM parquetFile WHERE age >= 13 AND age <= 19")
we have to add age column after SELECT in order to make it right:
sql("SELECT name , age FROM parquetFile WHERE age >= 13 AND age <= 19")
The same error also occurs when we use DSL:
parquetFile.where('key === 1).select('value as 'a).collect().foreach(println)
will tell us can not find column 'key',we have to fix like this :
parquetFile.where('key === 1).select('key ,'value as 'a).collect().foreach(println)
Obviously, that's not the way we want!
--
This message was sent by Atlassian JIRA
(v6.2#6252)