Yes, the current code throws directly for NULLs, can you log an issue there ?
Dylan Forciea <dy...@oseberg.io> 于2020年10月21日周三 上午4:30写道: > I believe I am getting an error because I have a nullable postgres array > of text that is set to NULL that I’m reading using the JDBC SQL Connector. > Is this something that should be allowed? Looking at the source code line > below, it doesn’t look like the case of an array being null would be > handled. > > > > [error] Caused by: java.io.IOException: Couldn't access resultSet > > [error] at > org.apache.flink.connector.jdbc.table.JdbcRowDataInputFormat.nextRecord(JdbcRowDataInputFormat.java:266) > > [error] at > org.apache.flink.connector.jdbc.table.JdbcRowDataInputFormat.nextRecord(JdbcRowDataInputFormat.java:57) > > [error] at > org.apache.flink.streaming.api.functions.source.InputFormatSourceFunction.run(InputFormatSourceFunction.java:91) > > [error] at > org.apache.flink.streaming.api.operators.StreamSource.run(StreamSource.java:100) > > [error] at > org.apache.flink.streaming.api.operators.StreamSource.run(StreamSource.java:63) > > [error] at > org.apache.flink.streaming.runtime.tasks.SourceStreamTask$LegacySourceFunctionThread.run(SourceStreamTask.java:213) > > [error] Caused by: java.lang.NullPointerException > > [error] at > org.apache.flink.connector.jdbc.internal.converter.PostgresRowConverter.lambda$createPostgresArrayConverter$c06ce9f4$2(PostgresRowConverter.java:97) > > [error] at > org.apache.flink.connector.jdbc.internal.converter.AbstractJdbcRowConverter.toInternal(AbstractJdbcRowConverter.java:79) > > [error] at > org.apache.flink.connector.jdbc.table.JdbcRowDataInputFormat.nextRecord(JdbcRowDataInputFormat.java:259) > > [error] ... 5 more > > > > Thanks, > > Dylan Forciea >