[
https://issues.apache.org/jira/browse/FLINK-3292?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15118884#comment-15118884
]
ASF GitHub Bot commented on FLINK-3292:
---------------------------------------
Github user zentol commented on a diff in the pull request:
https://github.com/apache/flink/pull/1551#discussion_r50955346
--- Diff:
flink-batch-connectors/flink-jdbc/src/main/java/org/apache/flink/api/java/io/jdbc/JDBCInputFormat.java
---
@@ -92,6 +94,15 @@ public void open(InputSplit ignored) throws IOException {
}
}
+ private Statement createStatement() throws SQLException {
+ if(resultSetType == 0 || resultSetConcurrency == 0) {
--- End diff --
this line might lead to confusion when a user only sets either the type or
concurrency.
IMO we should check with && here, require the user to set both type and
concurrency at the same time, and throw a meaningful exception if only one
these is 0.
> Bug in flink-jdbc. Not all JDBC drivers supported
> -------------------------------------------------
>
> Key: FLINK-3292
> URL: https://issues.apache.org/jira/browse/FLINK-3292
> Project: Flink
> Issue Type: Bug
> Components: other
> Affects Versions: 1.0.0
> Reporter: Subhobrata Dey
> Priority: Minor
> Fix For: 1.0.0
>
>
> Hello,
> In method open in JDBCInputFormat.java, while using dbConn.createStatement,
> the resultSetType & resultSetConcurrency are hardcoded.
> These two fields may vary with different JDBC drivers & hence it fails in a
> few cases like SAP HANA Jdbc driver.
> There are two variants of the method dbCon.createStatement, one with
> parameters & the other without parameters. Both should be supported.
> Thanks & regards,
> Subhobrata
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)