Presto 0.115t Documentation

6.2. JDBC Driver

6.2. JDBC Driver

Presto can be accessed from Java using the JDBC driver. The JDBC driver requires Java 1.6 or later. Download presto-jdbc.jar and add it to the class path of your Java application. The following JDBC URL formats are supported:

jdbc:presto://host:port
jdbc:presto://host:port/catalog
jdbc:presto://host:port/catalog/schema

For example, use the following URL to connect to Presto running on example.net port 8080 with the catalog hive and the schema sales:

jdbc:presto://example.net:8080/hive/sales