Snowflake CLONE Command

VeritableAutomatism avatar
VeritableAutomatism
·
·
Download

Start Quiz

Study Flashcards

Questions and Answers

What is the primary purpose of the CLONE command in the given context?

To create zero-copy clones of databases, schemas, and tables

What does the CLONE command support for databases and schemas using the IGNORE TABLES WITH INSUFFICIENT DATA RETENTION parameter?

Skipping tables that have been purged from Time Travel

How is the value specified for the exact date and time to use for Time Travel?

Explicitly cast to a TIMESTAMP

What does the parameter specifying the difference in seconds from the current time for Time Travel support?

<p>An integer or arithmetic expression in the form -N</p> Signup and view all the answers

What is the requirement for the query ID of a statement to be used as the reference point for Time Travel?

<p>It must reference a query executed within the last 14 days</p> Signup and view all the answers

What privilege(s) does your current role need to have on the source object to create a clone?

<p>OWNERSHIP on the database role and the CREATE DATABASE ROLE privilege on the target database</p> Signup and view all the answers

What happens if the time specified in the AT | BEFORE clause is beyond the data retention period for any child table in a database?

<p>The cloning operation for the child table is skipped</p> Signup and view all the answers

What happens to the load history of a cloned table in comparison to its source table?

<p>The load history of the source table is not included in the cloned table</p> Signup and view all the answers

What happens to Automatic Clustering when a new table is created using CREATE TABLE … CLONE syntax?

<p>Automatic Clustering is suspended for the new table</p> Signup and view all the answers

What must be done if a database role is already cloned to the target database when running the CREATE CLONE command?

<p>Drop the database role from the target database and try the CLONE command again</p> Signup and view all the answers

Study Notes

CLONE Command

  • Primary purpose of CLONE command is to create a copy of a database, schema, or table.

Clone Command with IGNORE TABLES WITH INSUFFICIENT DATA RETENTION

  • Supports cloning of databases and schemas, excluding tables with insufficient data retention.

Time Travel

  • Exact date and time for Time Travel is specified using the AT | BEFORE clause.
  • Parameter specifying the difference in seconds from the current time for Time Travel is supported.

Query ID Requirement

  • Query ID of a statement must be used as the reference point for Time Travel.

Privilege Requirement

  • Current role needs to have the relevant privilege on the source object to create a clone.

Data Retention Period

  • If the time specified in the AT | BEFORE clause is beyond the data retention period for any child table in a database, the command will not be executed.

Load History of Cloned Table

  • Load history of a cloned table is not affected, and it will be the same as its source table.

Automatic Clustering

  • When a new table is created using CREATE TABLE … CLONE syntax, Automatic Clustering is disabled.

Creating a Clone

  • If a database role is already cloned to the target database when running the CREATE CLONE command, the command will not overwrite the existing clone; instead, the existing clone will be preserved.

Studying That Suits You

Use AI to generate personalized quizzes and flashcards to suit your learning preferences.

Quiz Team

More Quizzes Like This

Use Quizgecko on...
Browser
Browser