1

I can save a dataframe using df.write.saveAsTable('tableName') and read the subsequent table with spark.table('tableName') but I'm not sure where the table is actually getting saved?

Tom
  • 11
  • 1

1 Answers1

1

It is stored under the default location of your database.

You can get the location by running the following spark sql query:

spark.sql("DESCRIBE TABLE EXTENDED tableName")

You can find the Location under the # Detailed Table Information section. Please find a sample output below: enter image description here

Sima
  • 11
  • 2