无法从JAVA连接到本地运行的apache钻取

时间:2016-06-17 23:55:47

标签: apache-drill

我收到以下错误

Running com.rms.importnumbermatching.TestExecuteDrillQuery SLF4J: Failed to       load class "org.slf4j.impl.StaticLoggerBinder". SLF4J: Defaulting to no-operation` (NOP) logger implementation SLF4J: See slf4j.org/codes.html#StaticLoggerBinder for further details. java.sql.SQLException: No suitable driver found for jdbc:drill:drillbit=localhost:31010 at java.sql.DriverManager.getConnection(DriverManager.java:689) at java.sql.DriverManager.getConnection(DriverManager.java:270) at

我有以下代码

    `Class.forName("org.apache.drill.jdbc.Driver");
      conn =          DriverManager.getConnection("jdbc:drill:drillbit=localhost:31010");
      stmt = conn.createStatement();`

我在POM中有以下依赖

<dependency> <groupId>org.apache.poi</groupId> <artifactId>poi</artifactId> <version>3.10-FINAL</version> </dependency> <dependency> <groupId>org.apache.poi</groupId> <artifactId>poi-ooxml</artifactId> <version>3.10-FINAL</version> </dependency> <dependency> <groupId>org.apache.drill.exec</groupId> <artifactId>drill-jdbc</artifactId> <version>1.4.0</version> </dependency>

我似乎无法连接到钻孔,第二行失败。给出错误&#34; java.sql.SQLException:没有为jdbc找到合适的驱动程序:drill:drillbit = localhost:31010&#34;

我在这里缺少什么?

0 个答案:

没有答案