BigQueryIO.writeTableRows() and withTimePartitioning() fails with CreateDisposition.CREATE_NEVER
- Dominant language
- Java
- Stars
- 8.7k
- Forks
- 4.7k
- Avg merge
- 1d 20h
- Merged PRs (30d)
- 196
Description
Using the withTimeParitioning() clause with CreateDisposition.CREATE_NEVER fails with the error message "Table with field based partitioning must have a schema." even when schema is provided.
See: [https://github.com/pbrumblay/bigqueryioproblems/blob/master/src/main/java/com/fearlesstg/TimePartitioningTest.java#L41](https://github.com/pbrumblay/bigqueryioproblems/blob/master/src/main/java/com/fearlesstg/TimePartitioningTest.java#L41)
There is also a possibly related error with the TimePartitioning object when the setter setType("DAY") is not used.
```
Incompatible table partitioning specification. Expects partitioning specification interval(type:day,field:PARTITION_DATE),
but input partitioning specification is interval(type:day,field:PARTITION_DATE)
```
See: [https://github.com/pbrumblay/bigqueryioproblems/blob/master/src/main/java/com/fearlesstg/TimePartitioningTest.java#L95](https://github.com/pbrumblay/bigqueryioproblems/blob/master/src/main/java/com/fearlesstg/TimePartitioningTest.java#L95)
Imported from Jira [BEAM-4364](https://issues.apache.org/jira/browse/BEAM-4364). Original Jira may contain additional context.
Reported by: pbrumblay.
Contributor guide
Assessment
This issue has not been assessed yet.