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

types: fix incorrect time fraction parsing method #9933

Merged
merged 9 commits into from
Apr 1, 2019

Conversation

WangXiangUSTC
Copy link
Contributor

What problem does this PR solve?

fix issue #9734
tidb don't support date time format like "2019.01.01"

What is changed and how it works?

some minor update, and add unit test

Check List

Tests

  • Unit test

Related changes

  • Need to cherry-pick to the release branch

@WangXiangUSTC
Copy link
Contributor Author

/run-all-tests

@qw4990
Copy link
Contributor

qw4990 commented Apr 1, 2019

/rebuild

@qw4990
Copy link
Contributor

qw4990 commented Apr 1, 2019

/run-all-tests

types/time.go Outdated Show resolved Hide resolved
types/time.go Outdated Show resolved Hide resolved
types/time.go Outdated Show resolved Hide resolved
@winkyao
Copy link
Contributor

winkyao commented Apr 1, 2019

Any reference mysql doc?

types/time.go Outdated Show resolved Hide resolved
Copy link
Contributor

@qw4990 qw4990 left a comment

Choose a reason for hiding this comment

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

LGTM

Copy link
Member

@zz-jason zz-jason left a comment

Choose a reason for hiding this comment

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

LGTM

@zz-jason
Copy link
Member

zz-jason commented Apr 1, 2019

/run-all-tests

@zz-jason zz-jason added status/LGT2 Indicates that a PR has LGTM 2. component/expression labels Apr 1, 2019
@zz-jason zz-jason changed the title datetime: support parse string like "2019.01.01" to compatible with mysql types: fix incorrect time fraction parsing method Apr 1, 2019
@codecov
Copy link

codecov bot commented Apr 1, 2019

Codecov Report

Merging #9933 into master will increase coverage by 0.3224%.
The diff coverage is 100%.

@@               Coverage Diff                @@
##             master      #9933        +/-   ##
================================================
+ Coverage   77.4719%   77.7943%   +0.3224%     
================================================
  Files           403        403                
  Lines         81809      82479       +670     
================================================
+ Hits          63379      64164       +785     
+ Misses        13711      13631        -80     
+ Partials       4719       4684        -35

@WangXiangUSTC
Copy link
Contributor Author

@winkyao I search the mysql's document, can't find the detail about the format of date time string. I just execute in mysql to check.

@zz-jason zz-jason merged commit bf9570a into pingcap:master Apr 1, 2019
@zz-jason
Copy link
Member

zz-jason commented Apr 1, 2019

@WangXiangUSTC Please cherry pick this PR to release 2.1

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants