How To: Access Hive tables using SparkR

ACTION

To access hive tables from spark Analyze, it is necessary to enable hive support. To accomplish this create a spark command in analyze and select "R" in sub command options. The following is a sample command:

library(SparkR)
sparkR.session(enableHiveSupport=TRUE)

df <- sql("show tables")
collect(df)

 

 

Have more questions? Submit a request

Comments

Powered by Zendesk