Databricks Data Engineer Associate Question 243
Select 3A data engineering team is tasked with creating tables in Databricks to store large datasets. They are deciding between managed and external tables. Which of the following statements correctly describe the differences between managed and external tables?
- A
When a managed table is dropped, the data is also deleted from the storage location.
- B
External tables store their data in the Databricks-managed storage location by default.
- C
For external tables, the data remains in its original location even if the table is dropped.
- D
Managed tables are preferred when the data lifecycle needs to be tightly controlled by Databricks.
- E
Switching a table from managed to external does not require any changes to the table's configuration.
Show answer and explanation
Correct answers: A, C, D
Explanation
Managed tables are fully controlled by Databricks, including storage and lifecycle, and dropping them deletes the data. External tables, in contrast, reference data in an external location, and dropping such a table only removes the table metadata without affecting the underlying data. These distinctions guide decisions based on data ownership and lifecycle management requirements.
- A. Correct.
Correct: Managed tables are owned by Databricks, and when dropped, their data is also deleted from the storage location.
- B. Incorrect.
Incorrect: External tables store their data in an external storage location specified by the user, not in the Databricks-managed storage by default.
- C. Correct.
Correct: External tables reference data stored in an external location, and dropping the table does not affect the underlying data.
- D. Correct.
Correct: Managed tables allow Databricks to control the data lifecycle, making them suitable when centralized data management is required.
- E. Incorrect.
Incorrect: Switching between managed and external tables requires configuration changes, as they are fundamentally different in how they handle data.