
Answer-first summary for fast verification
Answer: ALTER SCHEMA retail OWNER TO 'user@myteam.com'
The correct command to transfer ownership of a schema (or database, as they are interchangeable in this context) to another user is `ALTER SCHEMA schema_name OWNER TO principal`. This command alters the metadata associated with a schema by setting the owner to the specified principal. The username should be enclosed in back ticks. This method is preferred for auditing and metadata recording purposes. The correct answer is `ALTER SCHEMA retail OWNER TO 'user@myteam.com'`. For more information, refer to the ALTER SCHEMA documentation in Databricks SQL.
Author: LeetQuiz Editorial Team
Ultimate access to all questions.
No comments yet.
A data engineer is leaving your organization and currently owns the 'retail' database. As an administrator, you need to transfer the ownership of this database to 'user@myteam.com'. Which command should you use to achieve this?
A
GRANT OWNERSHIP TO 'user@myteam.com' ON retail
B
TRANSFER OWNERSHIP OF retail TO 'user@myteam.com'
C
CHANGE OWNER OF retail TO 'user@myteam.com'
D
ALTER DATABASE retail OWNER TO 'user@myteam.com'
E
ALTER SCHEMA retail OWNER TO 'user@myteam.com'