From the course: Advanced Snowflake: Deep Dive Cloud Data Warehousing and Analytics

Unlock this course with a free trial

Join today to access over 24,600 courses taught by industry experts.

Dropping and restoring tables

Dropping and restoring tables

- [Instructor] If you have Time Travel enabled for a particular table, you can drop that table, and if you're still within the Time Travel retention time, well, you can undrop the table and restore its contents. Let's go ahead and drop the In_Production table. The table was successfully dropped, and we can confirm this by running a Select Star operation. Select Star from In_Production will now give us an error, because that table does not exist anymore. Well, we are still within the seven day retention period for this In_Production table. In fact, we are within a few seconds. I can run Undrop Table In_Production, and the table will be restored. I now confirm that this table has indeed been restored by running a Select Star from In_Production. This should allow us to retrieve the results of this table, and that's indeed the case. The five rows in the active table are now available to us. Let's now change the data…

Contents