Skip to content

Format microsecond in prepare_constant#929

Merged
tyt2y3 merged 8 commits intoSeaQL:masterfrom
Huliiiiii:constant-to-string
Aug 2, 2025
Merged

Format microsecond in prepare_constant#929
tyt2y3 merged 8 commits intoSeaQL:masterfrom
Huliiiiii:constant-to-string

Conversation

@Huliiiiii
Copy link
Member

PR Info

Fixed the issue where milliseconds were truncated when formatting Value::Constant

  • Postgres
    Support microseconds
  • Mysql
    Support microseconds
  • Sqlite
    Support milliseconds, ignore extra digits

Bug Fixes

  • Fixed the issue where microseconds were truncated when formatting Value::Constant

@Expurple Expurple requested a review from tyt2y3 July 30, 2025 13:44
@tyt2y3 tyt2y3 merged commit 05ff5c0 into SeaQL:master Aug 2, 2025
6 of 14 checks passed
@Huliiiiii Huliiiiii deleted the constant-to-string branch August 2, 2025 22:20
tyt2y3 added a commit that referenced this pull request Aug 2, 2025
Fixed the issue where milliseconds were truncated when formatting
`Value::Constant`

-
[Postgres](https://www.postgresql.org/docs/current/datatype-datetime.html#DATATYPE-DATETIME-INPUT-TIMES)
  Support microseconds
-
[Mysql](https://dev.mysql.com/doc/refman/8.4/en/fractional-seconds.html)
  Support microseconds
- [Sqlite](https://sqlite.org/lang_datefunc.html)
  Support milliseconds, ignore extra digits

<!-- mention the related issue -->
- Closes #808

- [x] Fixed the issue where microseconds were truncated when formatting
`Value::Constant`

---------

Co-authored-by: Chris Tsang <chris.2y3@outlook.com>
@github-actions
Copy link

github-actions bot commented Aug 6, 2025

🎉 Released In 0.32.7 🎉

Thank you everyone for the contribution!
This feature is now available in the latest release. Now is a good time to upgrade!
Your participation is what makes us unique; your adoption is what drives us forward.
You can support SeaQL 🌊 by starring our repos, sharing our libraries and becoming a sponsor ⭐.

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.

SimpleExpr::Constant conversion to string drops second fractions

3 participants