Salesforce Data Cloud Zero-Copy connector: Security and privileges

This topic describes the privileges required to create and manage a Zero-Copy connector and the catalog-linked databases created from it. For the privileges for each command, see CREATE ZEROCOPY CONNECTOR, ALTER ZEROCOPY CONNECTOR, CREATE DATABASE (zero-copy connector-linked), and ALTER DATABASE (zero-copy connector-linked).

Access control requirements

A role used to execute this operation must have the following privileges at a minimum:

PrivilegeObjectNotes
CREATE ZEROCOPY CONNECTORSchemaRequired to create a Zero-Copy connector. By default, the schema owner has this privilege.
OPERATEZero-Copy connectorRequired to disconnect the connector.
USAGEZero-Copy connectorRequired to create a catalog-linked database from the connector. The owner role of a catalog-linked database must keep this privilege.
MODIFYZero-Copy connectorRequired to change the connector’s properties, such as its comment.
Any privilege (for example, MONITOR)Zero-Copy connectorRequired to view the connector and to list the data shares linked to it (SYSTEM$ZEROCOPY_CONNECTOR_LIST_SHARES).
OWNERSHIPZero-Copy connectorRequired to rename or drop the connector.
CREATE DATABASEAccountRequired to create a catalog-linked database (together with USAGE on the connector).
MODIFYCatalog-linked databaseRequired to change the database’s options with ALTER DATABASE … UPDATE LINKED_ZEROCOPY_CONNECTOR. The database owner has this privilege.
OWNERSHIPCatalog-linked databaseRequired to suspend or resume discovery.
USAGECatalog-linked database and its schemasRequired, together with SELECT on the views, to query the data.
SELECTViews in the catalog-linked databaseRequired to query a view.

For the privileges that a system function requires, see the reference page of the function. For example, to read the Enrollment ID, see SYSTEM$GET_ZEROCOPY_CONNECTOR_CONFIG.

For instructions on creating a custom role with a specified set of privileges, see Creating custom roles.

For general information about roles and privilege grants for performing SQL actions on securable objects, see Overview of Access Control.

Transfer ownership of a catalog-linked database

The owner role of a catalog-linked database must have the USAGE privilege on the connector. Before you transfer ownership with GRANT OWNERSHIP, grant USAGE on the connector to the new owner role:

GRANT USAGE ON ZEROCOPY CONNECTOR my_db.my_schema.my_sfdc_connector TO ROLE new_owner_role;

GRANT OWNERSHIP ON DATABASE my_sfdc_db TO ROLE new_owner_role COPY CURRENT GRANTS;

The transfer fails if the new owner role doesn’t have USAGE on the connector. If the owner role loses USAGE later, discovery stops until you grant the privilege again.

Connector states

A Zero-Copy connector moves through the states NEW, CONNECTING, CONNECTED, CONNECT_ERROR, DISCONNECTING, DISCONNECTED, and DISCONNECT_ERROR. For the operations that each state allows, see Connector states. For a Salesforce connector:

  • You don’t run CONNECT in Snowflake. The connector moves to CONNECTING when your Salesforce administrator saves a Snowflake V2 Data Share Target with the connector’s Enrollment ID.
  • If Salesforce Data Cloud isn’t ready yet, Snowflake retries for a while. While it retries, the connection_error column says that the connection will be retried. If the connector stays in CONNECT_ERROR, your Salesforce administrator starts the connection again from Salesforce Data Cloud. See Troubleshoot the Salesforce Data Cloud Zero-Copy connector.
  • You create catalog-linked databases only while the connector is CONNECTED.
  • After you disconnect, your Salesforce administrator can connect the connector again with the same Enrollment ID.
  • Zero-Copy connectors and catalog-linked databases don’t support UNDROP.