Skip to content

fix: correct date/time type format for postgresql#1001

Merged
sunng87 merged 4 commits intoGreptimeTeam:developfrom
sunng87:fix/timestamp-format-for-pg
Feb 15, 2023
Merged

fix: correct date/time type format for postgresql#1001
sunng87 merged 4 commits intoGreptimeTeam:developfrom
sunng87:fix/timestamp-format-for-pg

Conversation

@sunng87
Copy link
Copy Markdown
Member

@sunng87 sunng87 commented Feb 14, 2023

I hereby agree to the terms of the GreptimeDB CLA

What's changed and what's your intention?

This patch aligns date/time format with postgresql so that psycopg2 and psycopg3 can consume these types of date.

Checklist

  • I have written the necessary rustdoc comments.
  • I have added the necessary unit tests and integration tests.

Refer to a related PR or issue link (optional)

@codecov
Copy link
Copy Markdown

codecov bot commented Feb 15, 2023

Codecov Report

Merging #1001 (64d5032) into develop (374acc8) will decrease coverage by 0.29%.
The diff coverage is 52.08%.

❗ Current head 64d5032 differs from pull request most recent head c176780. Consider uploading reports for the commit c176780 to get more accurate results

@@             Coverage Diff             @@
##           develop    #1001      +/-   ##
===========================================
- Coverage    86.24%   85.95%   -0.29%     
===========================================
  Files          432      432              
  Lines        62494    62530      +36     
===========================================
- Hits         53897    53749     -148     
- Misses        8597     8781     +184     
Flag Coverage Δ
rust 85.95% <52.08%> (-0.29%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
src/servers/src/postgres/handler.rs 78.78% <37.14%> (-2.58%) ⬇️
src/common/time/src/timestamp.rs 94.55% <85.71%> (+<0.01%) ⬆️
src/common/time/src/date.rs 98.14% <100.00%> (+0.10%) ⬆️
src/common/time/src/datetime.rs 97.61% <100.00%> (+0.18%) ⬆️
src/object-store/src/test_util.rs 0.00% <0.00%> (-100.00%) ⬇️
src/common/substrait/src/df_expr.rs 30.81% <0.00%> (-16.56%) ⬇️
src/datanode/src/instance.rs 41.56% <0.00%> (-14.91%) ⬇️
tests-integration/src/test_util.rs 79.47% <0.00%> (-9.33%) ⬇️
src/datatypes/src/data_type.rs 98.26% <0.00%> (+0.34%) ⬆️
... and 4 more

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

Comment thread src/servers/Cargo.toml Outdated
Co-authored-by: LFC <bayinamine@gmail.com>
@sunng87 sunng87 enabled auto-merge (squash) February 15, 2023 09:18
Copy link
Copy Markdown
Contributor

@fengys1996 fengys1996 left a comment

Choose a reason for hiding this comment

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

LGTM

@sunng87 sunng87 merged commit cd0d58c into GreptimeTeam:develop Feb 15, 2023
paomian pushed a commit to paomian/greptimedb that referenced this pull request Oct 19, 2023
* fix: correct date/time type format for postgresql

* fix: tests for timestamp

* refactor: use Utc datetime for timestamp::to_chrono_datetime

* Update src/servers/Cargo.toml

Co-authored-by: LFC <bayinamine@gmail.com>

---------

Co-authored-by: LFC <bayinamine@gmail.com>
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.

3 participants