JDBC Driver
Java Environment Requirements
The Singdata Lakehouse JDBC driver requires Java version 1.8 or higher. Please ensure that your development environment has the appropriate version of Java installed and configured.
JDBC Driver Download
You can download and use the Singdata Lakehouse JDBC driver in the following two ways:
- Through Maven Dependency
Add the following dependency code to your project's
pom.xmlfile: - Directly download the SDK Jar package, you can find and download the corresponding version of the Jar package on the Maven repository page.
Configure JDBC Driver
To use the Singdata Lakehouse JDBC driver to connect to Singdata Lakehouse, you need to configure it according to the following steps:
JDBC Driver Class
In your JDBC application, use the com.clickzetta.client.jdbc.ClickZettaDriver class to load the driver.
JDBC Connection String
When using the JDBC driver to connect to Singdata Lakehouse, the syntax format of the JDBC connection string is as follows:
-
Connection Parameters Description:
-
<service_instance_name>: Lakehouse service instance name. When a Lakehouse service instance is activated in a specified Region, the system will automatically assign an instance name. You can find the Lakehouse instance name on the Singdata product console page.
-
<workspace_name>: Workspace name. -
<connection_params>: Supports defining parameters using the=format, with multiple parameters separated by the&symbol. Common parameters are listed in the table below:
-
| Parameter | Value |
|---|---|
| username | Singdata login username |
| password | Login user password |
| schema | Specifies the default schema to connect to, optional |
| virtualCluster | Configures the virtual cluster used by default for JDBC connections, optional. If not specified, you need to use the SQL command use vcluster <vc_name> after connecting to specify it for use |
| use_http=true | Whether to use the HTTP protocol, default is HTTPS. This parameter needs to be specified when using a private link connection |
