SYSTEM$SYNC_ZEROCOPY_OBJECTS
functionnot supportedCore SQL functionsStarts one discovery cycle for a catalog-linked database that was created from a Zero-Copy connector, without waiting for the next scheduled cycle. A discovery cycle finds schemas and tables that the partner added or removed. The function schedules the cycle and returns immediately. It doesn’t wait for discovery to finish, and it doesn’t refresh table metadata.
Syntax
SYSTEM$SYNC_ZEROCOPY_OBJECTS('<database_name>')
Parameters
| Name | Required | Description |
|---|---|---|
database_name | required | The name of the catalog-linked database to sync. Specify it as a string literal enclosed in single quotes. The database must be a catalog-linked database that was created with CREATE DATABASE … LINKED_ZEROCOPY_CONNECTOR. |
Returns
Returns a string that contains a JSON object.
Usage notes
- To follow the progress of the sync, use SYSTEM$CATALOG_LINK_STATUS.
- If the reason is INELIGIBLE because discovery is suspended, resume it with ALTER DATABASE … RESUME DISCOVERY, which requires the OWNERSHIP privilege on the database, and call the function again.
- To change how often discovery runs, set SYNC_INTERVAL_SECONDS with ALTER DATABASE … UPDATE LINKED_ZEROCOPY_CONNECTOR.
- The function fails for a database that wasn’t created from a Zero-Copy connector.
- The function changes which schemas and tables exist in the database. To make existing tables pick up the partner’s latest table metadata sooner, change the connector’s interval with SYSTEM$SET_ZEROCOPY_METADATA_AUTO_REFRESH_INTERVAL.
Access control requirements
A role used to execute this operation must have the MODIFY or OWNERSHIP privilege on the catalog-linked database. 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.