I am a newbie to azure databricks and trying to store query results in the database. I want to create a new database and table on the fly. if it exists then remove existing DB and tables and store query results in the newly created database. Currently, I am using a notebook to write my query in the azure databricks.
df =spark.sql ("""select * from tableName""");