Re: custom schema in spark throwing error

2015-12-21 Thread VISHNU SUBRAMANIAN
Try this val customSchema = StructType(Array( StructField("year", IntegerType, true), StructField("make", StringType, true), StructField("model", StringType, true) )) On Mon, Dec 21, 2015 at 8:26 AM, Divya Gehlot wrote: > >1. scala> import org.apache.spark.sql.hive.HiveContext >2. impor

custom schema in spark throwing error

2015-12-20 Thread Divya Gehlot
1. scala> import org.apache.spark.sql.hive.HiveContext 2. import org.apache.spark.sql.hive.HiveContext 3. 4. scala> import org.apache.spark.sql.hive.orc._ 5. import org.apache.spark.sql.hive.orc._ 6. 7. scala> import org.apache.spark.sql.types.{StructType, StructField, Strin