Skip to content

Allowed specifying timestamp literals in SQL #2842

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

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

egormanga
Copy link

Currently, specifying a timestamp as an ISO-format string in SQL fails with:
Error: Unexpected type: (expected) String != (__timestamp_micros_since_unix_epoch__: I64) (inferred)

This PR allows specifying it (along with other, possibly future string literal-based types), as well as fixes the incorrect type order in the above error message (the inferred one should be from SQL, and the expected is the column SATS type).

API and ABI breaking changes

None.

Expected complexity level and risk

1.

Note for reviewers: this should NOT allow anything irrelevant, as parse() that we call still checks for the types to match.

Testing

  • Manual test case: INSERTing a timestamp column and SELECTing WITH comparing it.

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.

1 participant