The Simple Guide To Snowflake Tables
The Simple Guide To Snowflake Tables
The Simple Guide To Snowflake Tables
to Tables in
Snowflake
masteringsnowflake.com
What you'll learn
Adam Morton
Data Retention
Adam Morton
Data Retention
Adam Morton
Fail-Safe
Adam Morton
Fail-Safe
Adam Morton
If you cannot see the
Adam Morton
The Simple Guide to tables in Snowflake
Ok, now let's move on to
the tables...
Adam Morton
Table types in
1. Permanent
2. Temporary
3. Transient
4. External
5. Directory
6. Dynamic (Public Preview)
7. Event (Public Preview)
8. Unistore/Hybrid (Private Preview)
9. Iceberg (Private Preview)
Adam Morton
Permanent Tables
CREATE TABLE
Adam Morton
Permanent Tables
Adam Morton
The Simple Guide to tables in Snowflake
Time travel is a whole
other discussion for a
different day and a
different carousel!
Adam Morton
Temporary Tables
Adam Morton
Temporary Tables
Adam Morton
Temporary Tables
Adam Morton
Transient Tables
Adam Morton
So what’s the difference
Adam Morton
External Tables
Adam Morton
External Tables
Adam Morton
External Tables
Adam Morton
External Tables
Adam Morton
External Tables
or
Adam Morton
Directory Tables
Adam Morton
Directory Tables
Adam Morton
Directory Tables
Adam Morton
Dynamic Tables
Adam Morton
Dynamic Tables
Adam Morton
Dynamic Tables
Adam Morton
Dynamic Tables
Adam Morton
Event Tables
Adam Morton
Event Tables
Adam Morton
Iceberg Tables
Adam Morton
So, how can you ensure
Adam Morton
So how does Iceberg
Adam Morton
Promotes Consistency
Adam Morton
How to use Iceberg
Adam Morton
Create an external
Adam Morton
The Simple Guide to tables in Snowflake
Now you can create one or more
Iceberg Tables using the External
Volume.
Adam Morton
Create the iceberg table
Adam Morton
Unistore/Hybrid Tables
Adam Morton
Unistore/Hybrid Tables
Adam Morton
Some benefits of
Adam Morton
New row-based storage
Adam Morton
How to create a hybrid
Adam Morton
The Simple Guide to tables in Snowflake
CREATE HYBRID TABLE Orders (
Orderkey number(38,0) PRIMARY
KEY,
Customerkey number(38,0),
Orderstatus varchar(20),
Totalprice number(38,0),
Orderdate timestamp_ntz,
Clerk varchar(50)
);
Adam Morton
The Simple Guide to tables in Snowflake
Of course, your application requires more
than a single table.
Adam Morton
The Simple Guide to tables in Snowflake
CREATE HYBRID TABLE Customers (
CustomerKey number(38,0)
PRIMARY KEY,
Customername varchar(50)
);
Adam Morton
The Simple Guide to tables in Snowflake
-- Create order table with foreign key
referencing the customer table
CREATE OR REPLACE HYBRID TABLE Orders
(
Orderkey number(38,0) PRIMARY KEY,
Customerkey number(38,0),
Orderstatus varchar(20),
Totalprice number(38,0),
Orderdate timestamp_ntz,
Clerk varchar(50),
CONSTRAINT fk_o_customerkey FOREIGN
KEY (Customerkey) REFERENCES
Customers(Customerkey),
INDEX index_o_orderdate (Orderdate));
Adam Morton
Et Voila!
Link in my profile
Adam Morton