-
Notifications
You must be signed in to change notification settings - Fork 409
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
support tidb truncate function #9842
Conversation
78f3918
to
94fe3cd
Compare
94fe3cd
to
4edc751
Compare
Signed-off-by: guo-shaoge <shaoge1994@163.com>
4edc751
to
c9e1895
Compare
Signed-off-by: guo-shaoge <shaoge1994@163.com>
Signed-off-by: guo-shaoge <shaoge1994@163.com>
65da584
to
1a9c7d8
Compare
777eff2
to
fc61386
Compare
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
// modified from <https://github.com/pingcap/tidb/blob/26237b35f857c2388eab46f9ee3b351687143681/types/helper.go#L33-L48>. | ||
|
||
// modified from https://github.com/pingcap/tidb/blob/26237b35f857c2388eab46f9ee3b351687143681/types/helper.go#L33-L48 and | ||
// https://github.com/pingcap/tidb/blob/26237b35f857c2388eab46f9ee3b351687143681/types/helper.go#L50-L61. |
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.
Seems that ConstPowOf10
can be used to optimize the code in Line 986 base = std::pow(10.0, frac)
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.
It needs more efforts to make sure correctness and performance improvement. Maybe we should to it in another pr
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.
create a new issue to record: #9860
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: gengliqi, yibin87 The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
/retest |
/retest |
What problem does this PR solve?
Issue Number: close #9846
Problem Summary:
What is changed and how it works?
Check List
Tests
Side effects
Documentation
Release note