[
https://issues.apache.org/jira/browse/NIFI-3076?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15684801#comment-15684801
]
ASF GitHub Bot commented on NIFI-3076:
--------------------------------------
GitHub user mattyb149 opened a pull request:
https://github.com/apache/nifi/pull/1254
NIFI-3076: Fixed handling of 'medium' unsigned integers in JdbcCommon
I tested with MySQL ("MEDIUMINT" is where the original issue was found) and
on PostgreSQL and Oracle, although I couldn't find types that would reproduce
the issue for the latter two. Rather I tested on all 3 (and Derby in the unit
tests) to make sure the additional logic doesn't break existing behavior with
respect to (signed and unsigned) integers, and verified that the fix does
indeed correctly process unsigned MEDIUMINT columns in MySQL.
You can merge this pull request into a Git repository by running:
$ git pull https://github.com/mattyb149/nifi NIFI-3076
Alternatively you can review and apply these changes as the patch at:
https://github.com/apache/nifi/pull/1254.patch
To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:
This closes #1254
----
commit 7d36040ec6996bc5300e94e50bbd07533ede0350
Author: Matt Burgess <[email protected]>
Date: 2016-11-21T21:33:12Z
NIFI-3076: Fixed handling of 'medium' unsigned integers in JdbcCommon
----
> ExecuteSQL error when table uses unsigned MEDIUMINT
> ---------------------------------------------------
>
> Key: NIFI-3076
> URL: https://issues.apache.org/jira/browse/NIFI-3076
> Project: Apache NiFi
> Issue Type: Bug
> Components: Extensions
> Reporter: Matt Burgess
>
> When using a MySQL table with a column defined as an unsigned MEDIUMINT, the
> following error occurs:
> ExecuteSQL[id=fa363402-bbc0-1802-ffff-ffff96aa31f4]
> ExecuteSQL[id=fa363402-bbc0-1802-ffff-ffff96aa31f4] failed to process session
> due to org.apache.avro.file.DataFileWriter$AppendWriteException:
> org.apache.avro.UnresolvedUnionException: Not in union ["null","long"]:
> 141419: org.apache.avro.file.DataFileWriter$AppendWriteException:
> org.apache.avro.UnresolvedUnionException: Not in union ["null","long"]: 141419
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)