nerdexam
Snowflake

SOL-C01 · Question #80

A data engineer needs to transfer ownership of a database named 'SALES DATA' to a role named 'DATA GOVERNANCE The engineer attempts to use the following command: 'GRANT OWNERSHIP ON DATABASE SALES DAT

The correct answer is C. The role executing the command does not have the 'OWNERSHIP' privilege on the `SALES DATA. In Snowflake's security model, only the role that currently holds OWNERSHIP on an object can transfer that ownership to another role. The failing command is most likely executed by a role that doesn't own SALES DATA, making it unauthorized to reassign ownership - regardless of ho

Snowflake Account and Security

Question

A data engineer needs to transfer ownership of a database named 'SALES DATA' to a role named 'DATA GOVERNANCE The engineer attempts to use the following command: 'GRANT OWNERSHIP ON DATABASE SALES DATA TO ROLE DATA GOVERNANCE. However, this command fails. What is the MOST likely reason for the failure?

Options

  • AThe `DATA GOVERNANCE role does not have the 'OWNERSHIP' privilege on the 'SALES DATA'
  • BThe correct syntax is 'ALTER DATABASE SALES_DATA OWNER TO ROLE
  • CThe role executing the command does not have the 'OWNERSHIP' privilege on the `SALES DATA
  • DOwnership can only be transferred to users, not roles.
  • EThe `SALES DATA database contains shared data; ownership cannot be transferred in such

How the community answered

(19 responses)
  • A
    21% (4)
  • B
    5% (1)
  • C
    53% (10)
  • D
    5% (1)
  • E
    16% (3)

Explanation

In Snowflake's security model, only the role that currently holds OWNERSHIP on an object can transfer that ownership to another role. The failing command is most likely executed by a role that doesn't own SALES DATA, making it unauthorized to reassign ownership - regardless of how the command is written.

Why the distractors are wrong:

  • A is backwards: DATA GOVERNANCE is the recipient of ownership, not the executor. The recipient doesn't need prior OWNERSHIP to receive it.
  • B is incorrect syntax for Snowflake - ALTER DATABASE ... OWNER TO ROLE is PostgreSQL-style. Snowflake uses GRANT OWNERSHIP ON DATABASE ..., which is actually the correct base syntax here.
  • D is false: Snowflake grants ownership to roles, not individual users. Users acquire privileges through role membership.
  • E is a plausible edge case (shared databases do have restrictions), but it's not the most likely general failure reason and isn't indicated by the scenario.

Memory tip: Think "you can only give what you own." Before any GRANT OWNERSHIP succeeds, verify that the executing role already holds OWNERSHIP on the target object - not the receiving role.

Topics

#GRANT OWNERSHIP#Database ownership#Privileges#RBAC

Community Discussion

No community discussion yet for this question.

Full SOL-C01 Practice