Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Analyze and fix timestamp rounding issue #1648

Open
stephaniewang526 opened this issue Oct 11, 2021 · 4 comments
Open

Analyze and fix timestamp rounding issue #1648

stephaniewang526 opened this issue Oct 11, 2021 · 4 comments
Labels
api: bigquery Issues related to the googleapis/java-bigquery API. techdebt type: process A process-related concern. May include testing, release, or the like.

Comments

@stephaniewang526
Copy link
Contributor

Original ticket

Per Tim's comment, we should consider a more exhaustive approach to fix timestamp rounding issue.

@product-auto-label product-auto-label bot added the api: bigquery Issues related to the googleapis/java-bigquery API. label Oct 11, 2021
@meredithslota meredithslota added priority: p2 Moderately-important priority. Fix may not be included in next release. type: bug Error or flaw in code with unintended results or allowing sub-optimal usage patterns. labels Oct 11, 2021
@stephaniewang526 stephaniewang526 added type: process A process-related concern. May include testing, release, or the like. and removed priority: p2 Moderately-important priority. Fix may not be included in next release. type: bug Error or flaw in code with unintended results or allowing sub-optimal usage patterns. labels Nov 5, 2021
@Neenu1995
Copy link
Contributor

This fix requires a breaking change. Consider fixing for next major version bump.

@nineinchnick
Copy link

Hi, I'm hitting this issue when trying to read the maximum possible timestamp from a BigQuery view. I expect a value of 253402300799.999999, but I'm getting a 253402300800.0. When querying the view in the web console, I'm getting the expected value of 9999-12-31 23:59:59.999999 UTC.

I stumbled on this when working on trinodb/trino#12346

I tried checking how formatOptions could be set, but that field doesn't exist in the QueryRequest model. It is mentioned in the API docs though: https://cloud.google.com/bigquery/docs/reference/rest/v2/jobs/query
I checked that the models are generated based on API specs generated from the Discovery service. formatOptions field is not present in the Discovery service: https://bigquery.googleapis.com/$discovery/rest?version=v2
This is where I got stuck, I can't figure out if there are any public sources for the Discovery service.

BTW Why this would be a breaking change? Maybe we could somehow expose formatOptions and leave the defaults as is.

@wendigo
Copy link

wendigo commented Feb 14, 2024

Is anyone working on that?

@nineinchnick
Copy link

I just found out there's a public issue tracker, so I reported it there too: https://issuetracker.google.com/u/1/issues/326260769

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
api: bigquery Issues related to the googleapis/java-bigquery API. techdebt type: process A process-related concern. May include testing, release, or the like.
Projects
None yet
Development

No branches or pull requests

5 participants