Skip To Content

Connect to Snowflake from ArcGIS

To connect to a Snowflake cloud data warehouse, install and configure client files to implement communication between ArcGIS and Snowflake and create database connection files from ArcGIS Pro. To publish web layers, the database connection files must be registered with the ArcGIS Enterprise portal's hosting server site. For best performance, deploy ArcGIS clients and the data warehouse in the same Snowflake cloud environment.

Typically, IT professionals install the ArcGIS software and the drivers required to connect to the data warehouse. They also configure network, firewall, and other communication channels necessary to allow communication between ArcGIS and the cloud data warehouse.

Next, the administrator of the cloud data warehouse creates accounts and grants the accounts privileges to access specific tables in the cloud data warehouse. The administrator can create a connection from ArcGIS Pro to the cloud data warehouse and share the connection file with publishers, or the administrator can provide publishers with the credentials necessary to allow them to create their own connection files.

To publish ArcGIS Server web services that reference data in the cloud data warehouse, publishers must register the database connection file with the ArcGIS GIS Server site that acts as the ArcGIS Enterprise portal's hosting server.

Install and configure drivers

To connect from ArcGIS Pro to Snowflake, you must install the latest Snowflake 64-bit ODBC driver for Microsoft Windows on the ArcGIS Pro machines and configure the driver. To publish a map image layer that contains data from Snowflake, you must install and configure the Snowflake 64-bit ODBC driver on each machine in the ArcGIS Enterprise portal's hosting server site.

Download the Snowflake ODBC driver from the Snowflake website, and install it on all ArcGIS client machines that will connect to Snowflake. Follow instructions provided by Snowflake to install and configure the driver.

Alter the init_user_param.sh script (Linux only)

If the portal's hosting server runs on Linux machines, you must install the drivers on each machine in the GIS Server site and configure the init_user_param.sh script on each machine to access the drivers.

Alter the init_user_param.sh script installed with ArcGIS Server to reference the drivers. You can access this script by browsing to the <ArcGIS Server installation directory>/arcgis/server/usr directory.

  1. Ensure that the ArcGIS Server installation owner on each machine has at least read and execute permissions on the data warehouse client libraries.
  2. Open the init_user_param.sh script in a text editor.
  3. Remove the comment marks (#) from the lines beginning with export. Replace <Location_to_ODBC_driver_manager_libraries> with the location of the ODBC driver manager on the machine, and replace <Location_to_libSnowflake.so> with the location of the Snowflake ODBC driver.

    #
    # Modify this section to configure a connection to Snowflake Data Warehouse
    # 
    # -----------------------------------------------------------------------
    export LIB_ODBC_DRIVER_MANAGER=<Location_to_ODBC_driver_manager_libraries>/libodbc.so.2
    export LD_PRELOAD=$LD_PRELOAD:$LIB_ODBC_DRIVER_MANAGER:<Location_to_libSnowflake.so>/libSnowflake.so

  4. Save and close the script.
  5. For the changes you made in the init_user_param.sh file to take effect, you must restart ArcGIS Server.

    To do this, run the stopserver.sh script, then run the startserver.sh script on each machine in the ArcGIS Server site.

    ./stopserver.sh

    ./startserver.sh

Create database connection files

In ArcGIS Pro, use the New Database Connection dialog box to create a connection to Snowflake.

  1. Open the Catalog pane in ArcGIS Pro.
  2. Right-click Databases and click New Database Connection.
  3. Choose Snowflake from the Database Platform drop-down list.
  4. Type the name of the Snowflake account in the Server text box.

    Type the name in a format similar to my_account.snowflakecomputing.com.

  5. Only user authentication is supported when you connect to Snowflake from ArcGIS.
  6. Type the user name and password for the credentials to use for authentication.

    Note:

    Enabling feature binning and creating a materialized view create objects in the default schema of the connecting user. If you intend to use this functionality, either ensure the connecting user is assigned a default schema in which they can create objects, or use the Advanced Options field to specify a different schema for the connection.

  7. If you will use the database connection file to publish web layers or use in geoprocessing models, you must check the Save User/Password check box.
  8. In the Role text box, specify the set of permissions to use for the connection.
  9. Choose the database to connect to from the Database drop-down list, or type the name of the database.
  10. In the Warehouse text box, provide the name of the compute resources to use for the connection.
  11. If you require parameters to connect in addition to those required in the previous steps, provide the additional parameters in the Advanced Options field.

    Separate the options with semicolons (;). Read the Snowflake documentation for information on additional and optional connection parameters.

    For example, to use a schema for the connection other than the connecting user's default schema and to configure the connection to wait 90 seconds for a response when connecting to the Snowflake service before returning a login failure error, type schema=gisdata;login_timeout=90 in the Advanced Options field.

  12. Click OK to create the connection file.

You can rename the file by typing a new name in the Catalog pane and pressing Enter.

Register with the hosting server

To allow ArcGIS Server sites to access the data, use the database connection file you created to add a registered data store in ArcGIS Pro or add a data store item in the portal.

Next steps

After you configure the ArcGIS clients to connect and create a database connection file, you and other organization members can do the following:

  • If publishers intend to create snapshots of data to be stored in the relational data store, ensure the ArcGIS Data Store administrator is aware of this and has configured sufficient memory and disk space on the relational data store machines and backup machines to accommodate it.
  • Analysts and publishers create a query layer in a map in ArcGIS Pro.