bigdata-docker-compose icon indicating copy to clipboard operation
bigdata-docker-compose copied to clipboard

Spark is not connected to Hive correctly.

Open dukechain2333 opened this issue 3 years ago • 0 comments

I have already create a new database in Hive, however, when I excute the following code in spark-shell, it seems that spark goes to the wrong metastore_db as shown in this this page Spark Documentation

scala> spark.sql("show databases").show()
+---------------+
|databaseName|
+---------------+
| default      |
+---------------+
hive> show databases;
OK
default
sparkda
Time taken: 0.984 seconds, Fetched: 2 row(s)

dukechain2333 avatar Apr 04 '22 13:04 dukechain2333