-
Notifications
You must be signed in to change notification settings - Fork 3.8k
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
builtins: make date_trunc(week, timestamp[tz]) truncate to Monday #42622
Merged
craig
merged 1 commit into
cockroachdb:master
from
otan-cockroach:otan-fix_date_trunc_week
Nov 20, 2019
Merged
builtins: make date_trunc(week, timestamp[tz]) truncate to Monday #42622
craig
merged 1 commit into
cockroachdb:master
from
otan-cockroach:otan-fix_date_trunc_week
Nov 20, 2019
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Release note (sql change): The `date_trunc` function, when used with `week`, previously truncated to Sunday. This PR will make it follow postgres more closely by truncating to Monday instead.
otan
force-pushed
the
otan-fix_date_trunc_week
branch
from
November 20, 2019 21:38
e22b4a4
to
495ecfb
Compare
rafiss
approved these changes
Nov 20, 2019
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 extremely fast turnaround! lgtm
Reviewed 3 of 3 files at r1.
Reviewable status: complete! 0 of 0 LGTMs obtained
bors r+ |
Build failed |
bors r+ flake looks unrelated |
Build failed (retrying...) |
craig bot
pushed a commit
that referenced
this pull request
Nov 20, 2019
42613: sql: add cast support to TimeTZ r=otan a=otan Refs: #26097 Added the various casts supported by postgres for `timetz`: ``` otan=# select castcontext, f.typname as "from", t.typname as to from pg_cast join pg_type as f ON (f.typelem = castsource) join pg_type as t on (t.typelem=casttarget) where castsource = 'timetz'::regtype or casttarget = 'timetz'::regtype; castcontext | from | to -------------+--------------+--------- i | _time | _timetz a | _timestamptz | _timetz i | _timetz | _timetz a | _timetz | _time (4 rows) ``` No release not required as this will be combined with a fully fleshed note for TimeTZ. Release note: None 42622: builtins: make date_trunc(week, timestamp[tz]) truncate to Monday r=otan a=otan Resolves #42612 Release note (sql change): The `date_trunc` function, when used with `week`, previously truncated to Sunday. This PR will make it follow postgres more closely by truncating to Monday instead. Co-authored-by: Oliver Tan <otan@cockroachlabs.com>
Build succeeded |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Resolves #42612
Release note (sql change): The
date_trunc
function, when used withweek
, previously truncated to Sunday. This PR will make it followpostgres more closely by truncating to Monday instead.