spark-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Ishwardeep Singh <ishwardeep.si...@impetus.co.in>
Subject Re: Loading already existing tables in spark shell
Date Mon, 24 Aug 2015 12:56:42 GMT
Hi Jeetendra,


I faced this issue. I did not specify the database where this table exists. Please set the
database by using "use <database>" command before executing the query.


Regards,

Ishwardeep


________________________________
From: Jeetendra Gangele <gangele397@gmail.com>
Sent: Monday, August 24, 2015 5:47 PM
To: user
Subject: Loading already existing tables in spark shell

Hi All I have few tables in hive and I wanted to run query against them with spark as execution
engine.

Can I direct;y load these tables in spark shell and run query?

I tried with
1.val sqlContext = new org.apache.spark.sql.hive.HiveContext(sc)
2.qlContext.sql("FROM event_impressions select count(*)") where event_impressions is the table
name.

It give me error saying "org.apache.spark.sql.AnalysisException: no such table event_impressions;
line 1 pos 5"

Does anybody hit similar issues?


regards
jeetendra

________________________________






NOTE: This message may contain information that is confidential, proprietary, privileged or
otherwise protected by law. The message is intended solely for the named addressee. If received
in error, please destroy and notify the sender. Any use of this email is prohibited when received
in error. Impetus does not represent, warrant and/or guarantee, that the integrity of this
communication has been maintained nor that the communication is free of errors, virus, interception
or interference.

Mime
View raw message