dhruva1995 commented on code in PR #4:
URL: 
https://github.com/apache/flink-connector-jdbc/pull/4#discussion_r1187884474


##########
flink-connector-jdbc/src/main/java/org/apache/flink/connector/jdbc/catalog/AbstractJdbcCatalog.java:
##########
@@ -522,6 +509,25 @@ protected List<String> extractColumnValuesBySQL(
         }
     }
 
+    protected static List<String> extractColumnValuesByStatement(
+            PreparedStatement ps, int columnIndex, Predicate<String> 
filterFunc, Object... params)
+            throws SQLException {
+        List<String> columnValues = Lists.newArrayList();
+        if (Objects.nonNull(params) && params.length > 0) {
+            for (int i = 0; i < params.length; i++) {
+                ps.setObject(i + 1, params[i]);
+            }
+        }
+        ResultSet rs = ps.executeQuery();

Review Comment:
   Nit Pick: though not related to your change but can you wrap the above line 
in try with resource block I think ResultSet also implements AutoClosable



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to