Skip to Content

Snowflake SnowPro Advanced Architect: Time Travel and Dropped Objects

Discover the limitations of cloning Snowflake schemas using Time Travel when dealing with dropped and recreated objects. Learn how schema history affects the ability to clone schemas at specific points in time.

Table of Contents

Question

An Architect has been asked to clone schema STAGING as it looked one week ago, Tuesday June 1st at 8:00 AM, to recover some objects.

The STAGING schema has 50 days of retention.

The Architect runs the following statement:

CREATE SCHEMA STAGING_CLONE CLONE STAGING at (timestamp => ‘2021-06-01 08:00:00’);

The Architect receives the following error: Time travel data is not available for schema STAGING. The requested time is either beyond the allowed time travel period or before the object creation time.

The Architect then checks the schema history and sees the following:

CREATED_ON|NAME|DROPPED_ON –
2021-06-02 23:00:00 | STAGING | NULL
2021-05-01 10:00:00 | STAGING | 2021-06-02 23:00:00

How can cloning the STAGING schema be achieved?

A. Undrop the STAGING schema and then rerun the CLONE statement.
B. Modify the statement: CREATE SCHEMA STAGING_CLONE CLONE STAGING at (timestamp => ‘2021-05-01 10:00:00’);
C. Rename the STAGING schema and perform an UNDROP to retrieve the previous STAGING schema version, then run the CLONE statement.
D. Cloning cannot be accomplished because the STAGING schema version was not active during the proposed Time Travel time period.

Answer

D. Cloning cannot be accomplished because the STAGING schema version was not active during the proposed Time Travel time period.

Explanation

The STAGING schema was dropped on 2021-06-02 at 23:00:00 and recreated with the same name. The requested time travel point, 2021-06-01 08:00:00, falls within the period when the previous version of the STAGING schema was already dropped. Time Travel can only access data that existed during the specified time, so cloning the schema as it appeared on 2021-06-01 08:00:00 is not possible.

Snowflake SnowPro Advanced Architect certification exam practice question and answer (Q&A) dump with detail explanation and reference available free, helpful to pass the Snowflake SnowPro Advanced Architect exam and earn Snowflake SnowPro Advanced Architect certification.