> ## Documentation Index
> Fetch the complete documentation index at: https://anaconda.com/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Access an existing Snowflake data warehouse

This tutorial walks you through connecting Anaconda Platform to your existing Snowflake data warehouse so you can query data from your workstations and Metaflow flows.

<Note>
  Creating a resource integration requires an administrator role. If you do not have administrator access, ask your administrator to create the integration before you begin.
</Note>

By the end of this tutorial, you will have:

* A Snowflake integration registered on the platform
* A workstation notebook that reads data from Snowflake
* A Metaflow flow that queries Snowflake

This tutorial assumes you already have a Snowflake database, user, and role set up. If you do not, see [Set up a Snowflake data warehouse](/docs/platform/tutorials/snowflake-setup-warehouse).

## Register the Snowflake integration

1. Select **Integrations** in the left-hand navigation.
2. Click **Snowflake** in the **Add an Integration** section.
3. Enter a name for the integration.
4. Enter a description for the integration.
5. Enter your Snowflake credentials.
6. Click **Add**.

The integration panel includes a query to run on Snowflake to establish the security integration.

## Download the tutorial content

Download the tutorial content to your workstation:

```bash theme={null}
outerbounds tutorials pull --url https://outerbounds-journeys-content.s3.us-west-2.amazonaws.com/main/journeys.tar.gz --destination-dir ~/learn
```

The Snowflake tutorial content is in `~/learn/snowflake`. If you prefer a different location, replace `~/learn` with a directory of your choice.

<Tip>
  This command downloads all tutorial content as a single bundle. If you've already worked through other tutorials, you likely already have this and do not need to run the command again.
</Tip>

## Query Snowflake from a notebook

Open the notebook in `00-nb` from the `~/learn/snowflake` directory. Before running it, update the `integration`, `schema`, and `table_name` variables with your Snowflake integration name, schema, and table. This notebook walks you through reading data from Snowflake.

## Query Snowflake from a flow

Open the `01-flow` directory from the `~/learn/snowflake` directory. This directory contains a Metaflow flow that queries Snowflake. Before running it, update the `my_integration`, `my_schema`, and `my_table_name` variables in `flow.py` with the same values you used in the notebook.

Run the flow:

```bash theme={null}
cd ~/learn/snowflake/01-flow
python flow.py --environment=fast-bakery run --with kubernetes
```

## Next steps

To build on this tutorial:

* Query multiple tables and join data across schemas.
* Build automated reporting pipelines that read from Snowflake.
* Integrate Snowflake queries into your ML training workflows.
