Skip to main content
Community Hub
TL;DR

Configure your Snowflake setup so Atlan can use system data metric functions (DMFs).

Your AI can read this via Docs MCPcurl -fsSL "https://docs.atlan.com/install-docs-mcp" | bashConnect

Configure Snowflake data metric functions

To use system data metric functions (DMFs) from Snowflake, configure the Snowflake objects that Atlan's data quality integration depends on: two roles, a dedicated service user, a database with its schemas, and the MANAGE_DMF secure procedure that Atlan calls to attach and manage DMFs.

Snowflake setup lives on one page

Set up Snowflake holds the current, complete SQL for this configuration, including the MANAGE_DMF procedure. The Snowflake-side steps are the same whether you start from the Snowflake connector or from Data Quality Studio, so they're maintained in one place rather than copied here.

Prerequisites​

Confirm the following before you start:

  • Snowflake Enterprise or Business Critical edition. Data quality for Snowflake doesn't support other editions.
  • ACCOUNTADMIN role in Snowflake, or equivalent administrative privileges.
  • Dedicated Snowflake warehouse for running data quality queries.

Configure Snowflake​

Follow Set up Snowflake, which covers these steps in order:

  1. Set the session variables that name your data quality database, warehouse, roles, and user. The database name is configurable, so you can repeat the setup for separate Atlan connections on the same Snowflake account.
  2. Create the DQ_ADMIN and ATLAN_DQ_SERVICE_ROLE roles and grant each one access to your data quality warehouse.
  3. Create the Snowflake user that Atlan connects as, then grant it the service role.
  4. Create the data quality database and its SHARED, DMFS, META, STORE, and CORE schemas.
  5. Create the MANAGE_DMF secure procedure, which attaches, detaches, suspends, resumes, and reschedules DMFs, creates custom DMFs, and turns anomaly detection on or off.
  6. Grant DQ_ADMIN ownership of the database, its schemas, and the procedure.
  7. Grant the service role the system privileges and object access it needs.

Update earlier setup​

This page previously included its own copy of the setup SQL. That copy defined an older MANAGE_DMF procedure that hardcoded the ATLAN_DQ database name, accepted seven parameters, and didn't implement the GET_PROCEDURE_VERSION action Atlan uses to check which procedure version is installed. Setups built from it can't use anomaly detection or custom DMFs.

If you configured Snowflake from that earlier SQL, follow Upgrade Snowflake Data Quality Studio to move to the current procedure without rebuilding your setup.

Next steps​

Enable data quality for Snowflake: Turn on data quality for your Snowflake connection in Atlan

See also​