Skip to content
English
  • There are no suggestions because the search field is empty.

How to Connect to Snowflake in Precog

This guide is specifically for setting up Snowflake as a destination in Precog. 

If you don’t already have a Snowflake account, that’s okay. You can start with a free 30-day trial, and no payment information is needed.

Precog setup

  1. Log in to your Precog account.

  2. Add a new data pipeline and select Snowflake as the destination.

  3. Follow the directions in Precog and supply the required information into the configuration form.

Snowflake setup

  1. Log in to your Snowflake account.

  2. Create a new SQL Worksheet. Click on + Create in the top left navigation and then choose SQL Worksheet.

  3. Paste the SQL statements provided to you by Precog into the new worksheet. This will create a service user, database, and warehouse named “precog”. This service user will be authenticated with a Public and Private Key pair. Precog generates the Public and Private Key pair for you. The Private Key is stored in your Preocg destination configuration. The Public Key is automatically added to the SQL statements that you will need to run in Snowflake. For more information on key pair authentication, refer to the Snowflake documentation.

    Example SQL statements that are provided to you by Precog.

    sql-example

    If you prefer, you can generate your own Public and Private Key pair. Please upload the Private Key PEM file into the Precog configuration form. Ensure that you replace the generated Public Key in the SQL statements provided by Precog. For further information, refer to the Snowflake documentation.

  4. Click on the Run All option, which is revealed after clicking on the down-arrow icon in the top right corner.

  5. After running the SQL statements, you will have a Database, Warehouse, and User named “precog”. These values have all been populated in the Precog configuration form. Please update the form if you modified the names or roles in the script.

  6. Find your Snowflake Account URL. Click on the "Account Admin" option in the bottom left navigation, displayed as a circle with your initials. Click on “Account”. In the next panel, click on "View account details". Look for the Account/Server URL. Copy and paste the URL in the Precog configuration form.

  7. Click on the “Create destination” button to connect Snowflake as a destination.