Skip to content

feat: add unix_seconds, unix_millis and unix_micros for timestamp series. #1297

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

Merged
merged 8 commits into from
Jan 21, 2025

Conversation

sycai
Copy link
Contributor

@sycai sycai commented Jan 16, 2025

No description provided.

@product-auto-label product-auto-label bot added size: m Pull request size is medium. api: bigquery Issues related to the googleapis/python-bigquery-dataframes API. labels Jan 16, 2025
@sycai sycai marked this pull request as ready for review January 17, 2025 20:43
@sycai sycai requested review from a team as code owners January 17, 2025 20:43
@sycai sycai requested a review from shobsi January 17, 2025 20:43
@GarrettWu GarrettWu removed their assignment Jan 17, 2025
Copy link
Contributor

@shobsi shobsi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Left a comment

@@ -722,6 +722,21 @@ def strftime_op_impl(x: ibis_types.Value, op: ops.StrftimeOp):
)


@scalar_op_compiler.register_unary_op(ops.UnixSeconds)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should we support these via sql_scalar added in #1293?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sql_scalar is cool, though I think well-defined operations such as epoch conversions should have their own op nodes because their behaviors are well-defined, and there's no need for dry runs to validate the syntax and return type. Plus, it might benefit from future tree optimizations.

@sycai sycai enabled auto-merge (squash) January 21, 2025 20:59
@sycai sycai merged commit e4b0c8d into main Jan 21, 2025
22 checks passed
@sycai sycai deleted the b388906290-unix-epoch branch January 21, 2025 21:44
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/python-bigquery-dataframes API. size: m Pull request size is medium.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants