nerdexam
SnowflakeSnowflake

COF-C02 · Question #532

COF-C02 Question #532: Real Exam Question with Answer & Explanation

The correct answer is C: Streams. In Snowflake, shares are used to share data across different Snowflake accounts securely. When you create a share, you can include various database objects that you want to share with consumers. According to Snowflake's documentation, the types of objects that can be shared inclu

Data Protection and Data Sharing

Question

Given the statement template below, which database objects can be added to a share?(Select TWO). GRANT <privilege> ON <object> <object_name> To SHARE <share_name>;

Options

  • ASecure functions
  • BStored procedures
  • CStreams
  • DTables
  • ETasks

Explanation

In Snowflake, shares are used to share data across different Snowflake accounts securely. When you create a share, you can include various database objects that you want to share with consumers. According to Snowflake's documentation, the types of objects that can be shared include tables, secure views, secure materialized views, and streams. Secure functions and stored procedures are not shareable objects. Tasks also cannot be shared directly. Therefore, the correct answers are streams (C) and tables (D). To share a stream or a table, you use the GRANT statement to grant privileges on these objects to a share. The syntax for sharing a table or stream involves specifying the type of object, the object name, and the share to which you are granting access. For example: GRANT SELECT ON TABLE my_table TO SHARE my_share; GRANT SELECT ON STREAM my_stream TO SHARE my_share; These commands grant the SELECT privilege on a table named my_table and a stream named my_stream to a share named my_share. This enables the consumer of the share to access these objects according to the granted privileges.

Topics

#Data Sharing#GRANT command#Shareable Objects#Snowflake Objects

Community Discussion

No community discussion yet for this question.

Full COF-C02 PracticeBrowse All COF-C02 Questions