[ https://issues.apache.org/jira/browse/SPARK-16562?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Hyukjin Kwon resolved SPARK-16562. ---------------------------------- Resolution: Not A Bug This seems not a problem to me. Please my PR linked. > Do not allow downcast in INT32 based types for non-vectorized Parquet reader > ---------------------------------------------------------------------------- > > Key: SPARK-16562 > URL: https://issues.apache.org/jira/browse/SPARK-16562 > Project: Spark > Issue Type: Sub-task > Components: SQL > Affects Versions: 2.0.0 > Reporter: Hyukjin Kwon > Priority: Minor > > Currently, INT32 based types, ({{ShortType}}, {{ByteType}}, {{IntegerType}} > can be downcasted in any combination. For example, the codes below: > {code} > val path = "/tmp/test.parquet" > val data = (1 to 4).map(Tuple1(_.toInt)) > data.toDF("a").write.parquet(path) > val schema = StructType(StructField("a", ShortType, true) :: Nil) > spark.read.schema(schema).parquet(path).show() > {code} > work fine. > This should not be allowed. -- This message was sent by Atlassian JIRA (v6.3.15#6346) --------------------------------------------------------------------- To unsubscribe, e-mail: issues-unsubscr...@spark.apache.org For additional commands, e-mail: issues-h...@spark.apache.org