Skip to content
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

CONVERT_TZ should return NULL if its arguments are invalid. (#11161) #11176

Merged
merged 3 commits into from
Jul 12, 2019

Conversation

tcmichael
Copy link

@tcmichael tcmichael commented Jul 10, 2019

What problem does this PR solve?

CONVERT_TZ should return NULL if its arguments are invalid
Closes #11161

What is changed and how it works?

  1. evalTime swallows error and makes isNull true when the arguments are invalid.
  2. validate that zone is not "".

Check List

Tests

  • Unit test

@tcmichael
Copy link
Author

/retest

@codecov
Copy link

codecov bot commented Jul 10, 2019

Codecov Report

❗ No coverage uploaded for pull request base (master@f496b77). Click here to learn what that means.
The diff coverage is n/a.

@@             Coverage Diff             @@
##             master     #11176   +/-   ##
===========================================
  Coverage          ?   81.4428%           
===========================================
  Files             ?        423           
  Lines             ?      90725           
  Branches          ?          0           
===========================================
  Hits              ?      73889           
  Misses            ?      11529           
  Partials          ?       5307

@tcmichael
Copy link
Author

@SunRunAway PTAL

@tcmichael
Copy link
Author

/retest

@SunRunAway SunRunAway requested review from qw4990 and lzmhhh123 July 11, 2019 05:08
Copy link
Contributor

@SunRunAway SunRunAway left a comment

Choose a reason for hiding this comment

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

LGTM

@SunRunAway
Copy link
Contributor

/run-all-tests

Copy link
Contributor

@SunRunAway SunRunAway left a comment

Choose a reason for hiding this comment

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

LGTM && PTAL @lzmhhh123

@SunRunAway SunRunAway added the status/LGT1 Indicates that a PR has LGTM 1. label Jul 12, 2019
@lzmhhh123
Copy link
Contributor

@tcmichael Please add some tests in

// for convert_tz

Then I will approve.

@tcmichael
Copy link
Author

@lzmhhh123 PTAL

Copy link
Contributor

@lzmhhh123 lzmhhh123 left a comment

Choose a reason for hiding this comment

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

LGTM.

@lzmhhh123
Copy link
Contributor

/run-all-tests

@lzmhhh123 lzmhhh123 added status/all tests passed status/LGT2 Indicates that a PR has LGTM 2. and removed status/LGT1 Indicates that a PR has LGTM 1. labels Jul 12, 2019
@lzmhhh123 lzmhhh123 merged commit 8d2c9be into pingcap:master Jul 12, 2019
@tcmichael tcmichael deleted the bugfix-11161 branch July 12, 2019 08:37
SunRunAway added a commit to SunRunAway/tidb that referenced this pull request Jul 22, 2019
SunRunAway added a commit to SunRunAway/tidb that referenced this pull request Jul 22, 2019
zz-jason added a commit to SunRunAway/tidb that referenced this pull request Jul 23, 2019
zz-jason added a commit to SunRunAway/tidb that referenced this pull request Jul 23, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
component/expression contribution This PR is from a community contributor. status/LGT2 Indicates that a PR has LGTM 2. type/compatibility
Projects
None yet
Development

Successfully merging this pull request may close these issues.

CONVERT_TZ should return NULL if its arguments are invalid.
3 participants