Skip to content
Permalink
Browse files

[SPARK-26499][SQL][FOLLOW-UP] Replace `update` with `setByte` for Byt…

…eType in JdbcUtils.makeGetter

### What changes were proposed in this pull request?

This is a follow-up pr to fix the code coming from #23400; it replaces `update` with `setByte` for ByteType in `JdbcUtils.makeGetter`.

### Why are the changes needed?

For better code.

### Does this PR introduce any user-facing change?

No.

### How was this patch tested?

Existing tests.

Closes #26532 from maropu/SPARK-26499-FOLLOWUP.

Authored-by: Takeshi Yamamuro <yamamuro@apache.org>
Signed-off-by: Sean Owen <sean.owen@databricks.com>
  • Loading branch information
maropu authored and srowen committed Nov 15, 2019
1 parent 4f10e54 commit ee4784bf26421b830f02c6d65faae4e546c622a8
@@ -445,7 +445,7 @@ object JdbcUtils extends Logging {

case ByteType =>
(rs: ResultSet, row: InternalRow, pos: Int) =>
row.update(pos, rs.getByte(pos + 1))
row.setByte(pos, rs.getByte(pos + 1))

case StringType =>
(rs: ResultSet, row: InternalRow, pos: Int) =>

0 comments on commit ee4784b

Please sign in to comment.
You can’t perform that action at this time.