Repository navigation
fix(bigquery): fix invalid mappings in domain models - #14646
Conversation
| } else if (String.class.isAssignableFrom(type)) { | ||
| return StandardSQLTypeName.GEOGRAPHY; |
There was a problem hiding this comment.
the above else blocks makes this unreachable
| } | ||
|
|
||
| /** | ||
| * Default instances created automatically by the static {@link #of(Object, Class)} method. |
There was a problem hiding this comment.
following the impl from other languages, this automatic conversion only works for native types. other types must be called via the type specific #of method
There was a problem hiding this comment.
Code Review
This pull request addresses several bugs and refactors code across the BigQuery library. Key changes include correcting self-assignment issues in IndexUnusedReason, fixing a typo in ExternalTableDefinition where the time format was used instead of the timestamp format, correcting a null check in JobStatistics, and refactoring type mappings in QueryParameterValue. Feedback on the changes in QueryParameterValue points out that using break statements in the JSON and INTERVAL cases of valueToStringOrNull allows unsupported types to fall through and be silently converted to strings, and suggests throwing an IllegalArgumentException instead.
|
Can we add unit tests for these changes? |
fc42699 to
aab8131
Compare
No description provided.