-
-
Notifications
You must be signed in to change notification settings - Fork 238
more precision fixes for unix_timestamp
#2918
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
Conversation
sql/expression/function/date.go
Outdated
|
|
||
| const MaxUnixTimeMicroSecs = 32536771199999999 | ||
|
|
||
| // noEval returns true if the expression contains an expression that cannot be evaluated without sql.Context or sql.Row. |
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.
update comment
max-hoffman
left a comment
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
sql/types/datetime.go
Outdated
| if dtType, isDtType := otherType.(sql.DatetimeType); isDtType { | ||
| return t.baseType == dtType.Type() && t.precision == dtType.Precision() | ||
| } | ||
| return t.baseType == otherType.Type() |
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?
| if dtType, isDtType := otherType.(sql.DatetimeType); isDtType { | |
| return t.baseType == dtType.Type() && t.precision == dtType.Precision() | |
| } | |
| return t.baseType == otherType.Type() | |
| if dtType, isDtType := otherType.(sql.DatetimeType); isDtType { | |
| return t.precision == dtType.Precision() | |
| } | |
| return false |
Changes:
fixes: dolthub/dolt#9025