-
Notifications
You must be signed in to change notification settings - Fork 31
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
Tests: Also use datetime
column within locations
test fixtures
#438
Conversation
It is filled with the same value as in the corresponding `date` column.
src/crate/client/doctests/client.txt
Outdated
@@ -213,7 +213,7 @@ supported, all other fields are 'None':: | |||
>>> pprint(result) | |||
['Aldebaran', | |||
1373932800000, | |||
None, | |||
1373932800000, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
maybe you can add also time info, down to millis?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sure. a7fa1ee brings in a corresponding improvement, which updates all the previous 1367366400000 timestamps.
On the other hand, I didn't change the timestamp 308534400000, it might have intentionally been set to 12 October 1979 00:00:00 UTC.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
As discussed, after that we need to add a column of DATE
to test table locations
, and we need also to add functionality to the client to truncate to start of day when using python date type, even if the table column (result) is a complete timestamp with time info.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you for the suggestion. I just looked up the definition of DATE
again, and it also says within the Note admonition down the line
You cannot create table columns of type
DATE
. 1
So, I think TIMESTAMP
is really the only type which can be actually stored. Maybe it makes sense to exercise both variants TIMESTAMP WITH TIME ZONE
and/vs. TIMESTAMP WITHOUT TIME ZONE
instead?
Footnotes
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I've added #439 a followup. Let me know if that makes sense in this context, in order to further improve this spot.
All the timestamps included only time information to the hour-level. This patch makes it use the full capabilities of milliseconds.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, added a followup task/improvement as discussed.
Hi,
this patch will be good to have before #437 in order to better outline specific changes to
date
vs.datetime
return values.All the values in the
datetime
column have been filled with the same value as in the correspondingdate
column. No other values have been changed.With kind regards,
Andreas.