# snowflake-jdbc
**Repository Path**: mirrors_dremio/snowflake-jdbc
## Basic Information
- **Project Name**: snowflake-jdbc
- **Description**: No description available
- **Primary Language**: Unknown
- **License**: Apache-2.0
- **Default Branch**: master-dremio
- **Homepage**: None
- **GVP Project**: No
## Statistics
- **Stars**: 0
- **Forks**: 0
- **Created**: 2022-11-02
- **Last Updated**: 2026-05-09
## Categories & Tags
**Categories**: Uncategorized
**Tags**: None
## README
Snowflake JDBC Driver
*********************
.. image:: https://github.com/snowflakedb/snowflake-jdbc/workflows/Build%20and%20Test/badge.svg?branch=master
:target: https://github.com/snowflakedb/snowflake-jdbc/actions?query=workflow%3A%22Build+and+Test%22+branch%3Amaster
.. image:: http://img.shields.io/:license-Apache%202-brightgreen.svg
:target: http://www.apache.org/licenses/LICENSE-2.0.txt
.. image:: https://maven-badges.herokuapp.com/maven-central/net.snowflake/snowflake-jdbc/badge.svg?style=plastic
:target: http://repo2.maven.org/maven2/net/snowflake/snowflake-jdbc/
Snowflake provides a JDBC type 4 driver that supports core functionality, allowing Java program to connect to Snowflake.
Prerequisites
=============
The Snowflake JDBC driver requires Java 1.8 or higher. If the minimum required version of Java is not installed on the client machines where the JDBC driver is installed, you must install either Oracle Java or OpenJDK.
Installation
============
Maven
-----
Add following code block as a dependency
.. code-block:: xml
net.snowflake
snowflake-jdbc
{version}
Build from Source Code
----------------------
1. Checkout source code from Github by running:
.. code-block:: bash
git clone https://github.com/snowflakedb/snowflake-jdbc.git
2. Build the driver by running:
.. code-block:: bash
mvn install
Usage
=====
Load Driver Class
-----------------
.. code-block:: java
Class.forName("net.snowflake.client.jdbc.SnowflakeDriver")
Datasource
----------
javax.sql.DataSource interface is implemented by class
.. code-block:: java
net.snowflake.client.jdbc.SnowflakeBasicDataSource
Connection String
-----------------
US(West) Region:
.. code-block:: bash
jdbc:snowflake://.snowflakecomputing.com/?
EU(Frankfurt) Region:
.. code-block:: bash
jdbc:snowflake://.eu-central-1.snowflakecomputing.com/?
Documentation
=============
For detailed documentation, please refer to https://docs.snowflake.net/manuals/user-guide/jdbc.html
Development
=============
Run the maven command to check the coding style.
.. code-block:: bash
mvn -P check-style verify
Follow the instruction if any error occurs or run this command to fix the formats.
.. code-block:: bash
mvn com.coveo:fmt-maven-plugin:format
You may import the coding style from IntelliJ so that the coding style can be applied on IDE:
- In the **File** -> **Settings/Plugins**, and install `google-java-format` plugin.
- Enable `google-java-format` for the JDBC project.
- In the source code window, select **Code** -> **Reformat** to apply the coding style.
Tests
=====
Run Tests
---------
Set the environment variables to specify the target database.
.. code-block:: bash
export SNOWFLAKE_TEST_HOST=
export SNOWFLAKE_TEST_ACCOUNT=
export SNOWFLAKE_TEST_USER=
export SNOWFLAKE_TEST_PASSWORD=
export SNOWFLAKE_TEST_DATABASE=
export SNOWFLAKE_TEST_SCHEMA=
export SNOWFLAKE_TEST_WAREHOUSE=
export SNOWFLAKE_TEST_ROLE=
Run the maven ``verify`` goal.
.. code-block:: bash
mvn -DjenkinsIT -DtestCategory=net.snowflake.client.category. verify
where ``category`` is the class name under the package ``net.snowflake.client.category``.
Test Class Naming Convention
----------------------------
The test cases are fallen into a couple of criteria:
- The unit test class names end with ``Test``. They run part of the JDBC build jobs.
- The integration test class names end with ``IT``. They run part of the ``verify`` maven goal along with the test category specified by the parameter ``testCategory`` having ``net.snowflake.client.category`` classes.
- The manual test class names end with ``Manual``. They don't run in the CI but you can run them manually.
Aside from the general test criteria, the test case class names ending with ``LatestIT`` run only with the latest JDBC driver.
The main motivation behind is to skip those tests for the old JDBC driver. See ``./TestOnly`` directory for further information.
Support
=============
Feel free to file an issue or submit a PR here for general cases. For official support, contact Snowflake support at:
https://community.snowflake.com/s/article/How-To-Submit-a-Support-Case-in-Snowflake-Lodge