Skip to content

Commit

Permalink
Improve error message
Browse files Browse the repository at this point in the history
  • Loading branch information
wendigo authored and hashhar committed Nov 7, 2022
1 parent ed8bc5b commit 21d669f
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ public JdbcRecordCursor(JdbcClient jdbcClient, ExecutorService executor, Connect
for (int i = 0; i < this.columnHandles.length; i++) {
JdbcColumnHandle columnHandle = columnHandles.get(i);
ColumnMapping columnMapping = jdbcClient.toColumnMapping(session, connection, columnHandle.getJdbcTypeHandle())
.orElseThrow(() -> new VerifyException("Unsupported column type"));
.orElseThrow(() -> new VerifyException("Column %s has unsupported type %s".formatted(columnHandle.getColumnName(), columnHandle.getJdbcTypeHandle())));
verify(
columnHandle.getColumnType().equals(columnMapping.getType()),
"Type mismatch: column handle has type %s but %s is mapped to %s",
Expand Down

0 comments on commit 21d669f

Please sign in to comment.