-
Notifications
You must be signed in to change notification settings - Fork 181
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[FEAT] Support for Timestamp datatype. (#1032)
Adds support for an Arrow-like Timestamp datatype in Daft. Timestamp type is parameterized by (TimeUnit, TimeZone). **Storage format** - TimeUnit and TimeZone are stored in the field only. They are stored in the Arrow format (TimeUnit enum, TimeZone Option<String>). - Timestamps are stored in the Arrow format: i64 representing number of TimeUnits from the UNIX epoch. **String representation** - All timestamps are printed in ISO 8601. - The number of subsecond digits printed reflects the resolution of the timestamp type. - All timezones are printed in offset format (+-XX:XX) regardless of the timezone. **Ingestion** - Lossless ingestion from PyArrow tables. - Ingestion from Python datetime.datetime to Timestamp(us, tz). **Casting** - Cast to and from integer types. - Cast to and from String type (ISO 8601 only) **Expressions** - Blackbox **Drivebys** Updated arrow_cast for Daft Physical -> Daft Logical. - Previously, casted directly to Arrow Physical. - Updated, casts to Arrow Logical and then to Arrow Physical. ### Separate PR: - Numeric expressions (requires Duration type) --------- Co-authored-by: Xiayue Charles Lin <charles@eventualcomputing.com>
- Loading branch information
1 parent
682dfed
commit 6206c92
Showing
23 changed files
with
690 additions
and
48 deletions.
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.