Created on 07-28-2014 10:28 AM - edited 09-16-2022 02:03 AM
I'm creating a simple SparkSQL app based on this post by Sandy:
http://blog.cloudera.com/blog/2014/04/how-to-run-a-simple-apache-spark-app-in-cdh-5/
But 'mvn package' gives throws error:
error: object sql is not a member of package org.apache.spark
Any idea if I need to include any other dependency?
Thanks!
Created 07-28-2014 10:30 AM
It sounds like you did not add a dependency on Spark SQL in your project. The artifact ID is "spark-sql_2.10"
Created 07-28-2014 10:38 AM
Thanks Sean, now I get this:
error: object SQLContext is not a member of package org.apache.spark.sql
[INFO] Note: class SQLContext exists, but it has no companion object.
[INFO] import org.apache.spark.sql.SQLContext._
Created 07-28-2014 10:43 AM
After removing the import, I was able to compile the package successfully.
Created 07-22-2015 05:08 AM
Hi,
Can you please post the exact order of your imports? I am having the same issue.
Thanks in advance.