Skip to content

feat(isthmus): enable precision timestamp addition/subtraction#745

Merged
andrew-coleman merged 1 commit intosubstrait-io:mainfrom
nielspardon:par-datetimeadd
Mar 12, 2026
Merged

feat(isthmus): enable precision timestamp addition/subtraction#745
andrew-coleman merged 1 commit intosubstrait-io:mainfrom
nielspardon:par-datetimeadd

Conversation

@nielspardon
Copy link
Member

This PR adds support for precision timestamp addition/subtraction in isthmus.

  • Previously, the mapping code only supported the old timestamp types.
  • Also fixes the use of type names to use the proper short names.
  • Removes time for the DATETIME_PLUS mapping since that is not officially supported in the default Substrait extension:io.substrait:functions_datetime collection.
  • Adds testcases for date, precision_timestamp and precision_timestamp_tz (generated by IBM Bob but I checked them)

SqlStdOperatorTable.PLUS, Set.of("i8", "i16", "i32", "i64", "fp32", "fp64", "dec")),
SqlStdOperatorTable.DATETIME_PLUS,
resolver(SqlStdOperatorTable.PLUS, Set.of("date", "time", "timestamp")),
resolver(SqlStdOperatorTable.DATETIME_PLUS, Set.of("date", "ts", "tstz", "pts", "ptstz")),
Copy link
Member Author

@nielspardon nielspardon Mar 11, 2026

Choose a reason for hiding this comment

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

this somehow still did work with the less specific/wrong SqlOperator. now it uses the right one

Signed-off-by: Niels Pardon <par@zurich.ibm.com>
@andrew-coleman andrew-coleman merged commit df13eb8 into substrait-io:main Mar 12, 2026
12 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants