
Ultimate access to all questions.
Answer-first summary for fast verification
Answer: Dropping `new_employees` deletes its data, while `employees` data remains unaffected.
The `DROP` command removes the specified database and its contents. Even though `employees` and `new_employees` share the same location, they are treated as separate entities. Dropping `new_employees` only affects its data, leaving `employees` intact. - **A** is incorrect because databases can share the same location. - **B** is incorrect; the `DROP` command works regardless of location sharing. - **D** is incorrect as it inaccurately suggests both databases' data will be deleted. - **E** is incorrect because the `DROP` command does delete the specified database's data.
Author: LeetQuiz Editorial Team
No comments yet.
A data engineer created a database named employees with the command CREATE DATABASE employees LOCATION ‘/employees‘. Later, a junior data engineer created a test database named new_employees using the same location with CREATE DATABASE new_employees LOCATION ‘/employees‘. After testing, the junior engineer drops the new_employees database. What happens to the data in both databases?
A
Creating new_employees with the same location as employees is not allowed.
B
Databases sharing the same location cannot be dropped.
C
Dropping new_employees deletes its data, while employees data remains unaffected.
D
All data in both databases will be deleted.
E
No data is deleted, but the DROP command succeeds.