diff options
author | baishuo(白硕) <vc_java@hotmail.com> | 2014-06-03 13:39:47 -0700 |
---|---|---|
committer | Michael Armbrust <michael@databricks.com> | 2014-06-03 13:39:47 -0700 |
commit | aa41a522d821c989c65fa3f7f2a4d372e39bb958 (patch) | |
tree | 4457f1fba8495c88d4a9b99acdaeee49b5356073 /LICENSE | |
parent | 8edc9d0330c94b50e01956ae88693cff4e0977b2 (diff) | |
download | spark-aa41a522d821c989c65fa3f7f2a4d372e39bb958.tar.gz spark-aa41a522d821c989c65fa3f7f2a4d372e39bb958.tar.bz2 spark-aa41a522d821c989c65fa3f7f2a4d372e39bb958.zip |
fix java.lang.ClassCastException
get Exception when run:bin/run-example org.apache.spark.examples.sql.RDDRelation
Exception's detail is:
Exception in thread "main" java.lang.ClassCastException: java.lang.Long cannot be cast to java.lang.Integer
at scala.runtime.BoxesRunTime.unboxToInt(BoxesRunTime.java:106)
at org.apache.spark.sql.catalyst.expressions.GenericRow.getInt(Row.scala:145)
at org.apache.spark.examples.sql.RDDRelation$.main(RDDRelation.scala:49)
at org.apache.spark.examples.sql.RDDRelation.main(RDDRelation.scala)
change sql("SELECT COUNT(*) FROM records").collect().head.getInt(0) to sql("SELECT COUNT(*) FROM records").collect().head.getLong(0), then the Exception do not occur any more
Author: baishuo(白硕) <vc_java@hotmail.com>
Closes #949 from baishuo/master and squashes the following commits:
f4b319f [baishuo(白硕)] fix java.lang.ClassCastException
Diffstat (limited to 'LICENSE')
0 files changed, 0 insertions, 0 deletions