From b1f5867157ba07be3af503607273ecd84c24754a Mon Sep 17 00:00:00 2001 From: Ulrich Kramer Date: Fri, 8 Dec 2023 14:35:46 +0100 Subject: [PATCH] [CALCITE-5409] Implement BatchNestedLoopJoin for JDBC --- .../java/org/apache/calcite/runtime/ResultSetEnumerable.java | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/core/src/main/java/org/apache/calcite/runtime/ResultSetEnumerable.java b/core/src/main/java/org/apache/calcite/runtime/ResultSetEnumerable.java index 2f9917735276..5d60b6552f38 100644 --- a/core/src/main/java/org/apache/calcite/runtime/ResultSetEnumerable.java +++ b/core/src/main/java/org/apache/calcite/runtime/ResultSetEnumerable.java @@ -17,7 +17,6 @@ package org.apache.calcite.runtime; import org.apache.calcite.DataContext; -import org.apache.calcite.avatica.SqlType; import org.apache.calcite.linq4j.AbstractEnumerable; import org.apache.calcite.linq4j.Enumerable; import org.apache.calcite.linq4j.Enumerator; @@ -203,8 +202,7 @@ public static PreparedStatementEnricher createEnricher(Integer[] indexes, private static void setDynamicParam(PreparedStatement preparedStatement, int i, @Nullable Object value) throws SQLException { if (value == null) { - // TODO: use proper type instead of ANY - preparedStatement.setObject(i, null, SqlType.ANY.id); + preparedStatement.setNull(i, Types.NULL); } else if (value instanceof Timestamp) { preparedStatement.setTimestamp(i, (Timestamp) value); } else if (value instanceof Time) {