是否可以CALL system.sync_partition_metadata('dummy','dummy','FULL')
使用 JDBC 执行 Presto JDBC 驱动程序不支持 CallableStatements?
问问题
137 次
1 回答
4
Presto JDBC 驱动程序不支持io.prestosql.jdbc.PrestoConnection#prepareCall
方法(请提出问题),但您可以使用Statement
:
try (Connection connection = DriverManager.getConnection("jdbc:presto://localhost:8080/hive/default", "presto", "")) {
try (Statement statement = connection.createStatement()) {
boolean hasResultSet = statement.execute("CALL system.sync_partition_metadata('default', 'table_name', 'FULL')");
verify(!hasResultSet, "unexpected resultSet");
}
}
(顺便说一句,您总是可以在Trino(以前的 Presto SQL)社区 slack上获得有关 Presto 的更多帮助)
于 2020-10-06T14:13:25.367 回答