Snowflake is a cloud-based data warehouse provided as Software-as-a-Service (SaaS). It offers all the features of a modern data warehouse, including scalability, ease of use, secure access to your data, accelerated analytics capabilities, and much more.
RudderStack allows you to configure Snowflake as a destination to dump your event data seamlessly.
To enable RudderStack access, please make sure you have an
ACCOUNTADMIN, or an account that has
The following sections illustrate how to create a virtual warehouse, a database, a role, and an user in Snowflake:
X-Small warehouseby following the wizard on Snowflake's website as shown in the screenshot below:
Alternatively, you can also use SQL to create a warehouse, as shown:
CREATE WAREHOUSE "RUDDER_WAREHOUSE"WITH WAREHOUSE_SIZE = 'XSMALL'WAREHOUSE_TYPE = 'STANDARD'AUTO_SUSPEND = 600AUTO_RESUME = TRUE;
The following screenshot demonstrates the Create Database option in Snowflake.
Alternatively, you can also use SQL to create a database, as shown:
CREATE DATABASE "RUDDER_EVENTS";
Please execute the following SQL commands to create a new role with the required permissions to load your data into the warehouse:
Create a new role
CREATE ROLE "RUDDER";
Grant access to the virtual warehouse
GRANT USAGE ON WAREHOUSE "RUDDER_WAREHOUSE" TO ROLE "RUDDER";
Grant access to the database
GRANT USAGE ON DATABASE "RUDDER_EVENTS" TO ROLE "RUDDER";GRANT CREATE SCHEMA ON DATABASE "RUDDER_EVENTS" TO ROLE "RUDDER";
Finally, please create a user to connect RudderStack to the previously created Snowflake warehouse, as shown:
Alternatively, you can use SQL to create a user in Snowflake, as shown:
CREATE USER "RUDDER_USER"MUST_CHANGE_PASSWORD = FALSEDEFAULT_ROLE = "RUDDER"PASSWORD = "strong_unique_password";GRANT ROLE "RUDDER" TO USER "RUDDER_USER";
In order to enable dumping data to Snowflake, you will first need to add it as a destination to the source from which you are sending event data. Once the destination is enabled, events from RudderStack will start to flow to Snowflake.
To do so, please follow these steps:
Choose a source to which you would like to add Snowflake as a destination. You can also simply create a destination and connect it to a source later.
After choosing a source, select Snowflake from the list of destinations.
Give your destination a name and then click on Next. You should then see the following screen:
Add the required credentials in the Connection Settings as described below:
Account - This is the account ID of your warehouse. Account ID is part of the snowflake url. The following examples illustrate the slight differences in the account ID for various cloud providers.
Account ID sample
Snowflake cloud provider
Amazon Web Services (AWS)
Microsoft Azure (Azure)
Google Cloud Platform (GCP)
Database - The name of the database, as created in the Creating a database section
Warehouse - The name of the warehouse, as created in the Creating a virtual warehouse section
User - This is the username, as created in Creating a user section.
Password - This is the password, as created in Creating a user section.
S3 bucket name - This is your unique S3 bucket name
AWS Access Key ID - This can be obtained from the AWS Console.
AWS Secret Access Key - This can be obtained from AWS Console. Please refer to the Setting Up Amazon S3 section for more details.