Ultimate access to all questions.
Upgrade Now 🚀
Sign in to unlock AI tutor
Explain the process of creating a managed table in Databricks using PySpark. Include the necessary code snippet and explain each step of the process.
A
df = spark.table("source_table"); df.write.saveAsTable("managed_table")
B
spark.sql('CREATE MANAGED TABLE managed_table AS SELECT * FROM source_table');
C
spark.read.format('delta').load('/path/to/data').createOrReplaceTempView('managed_table');
D
spark.sql('CREATE TABLE managed_table USING DELTA LOCATION '/path/to/data';');