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

parser: fix alter_stmt order by syntax #526

Merged
merged 10 commits into from
Aug 29, 2019
Merged

parser: fix alter_stmt order by syntax #526

merged 10 commits into from
Aug 29, 2019

Conversation

zuoRambo
Copy link
Contributor

What problem does this PR solve?

Fix ORDER BY syntax. Issue: #499

MySQL Syntax:

alter_specification:
...
  | ORDER BY col_name [, col_name] ...

Bad SQL Case:

ALTER TABLE t_n ORDER BY ident

Check List

Tests

  • Unit test

Code changes

  • Has exported variable/fields change
  • Has interface methods change

Related changes

  • Need to update the documentation

@CLAassistant
Copy link

CLAassistant commented Aug 27, 2019

CLA assistant check
All committers have signed the CLA.

@codecov
Copy link

codecov bot commented Aug 27, 2019

Codecov Report

Merging #526 into master will decrease coverage by <.01%.
The diff coverage is 69.23%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #526      +/-   ##
==========================================
- Coverage   71.77%   71.76%   -0.01%     
==========================================
  Files          32       32              
  Lines        7787     7800      +13     
==========================================
+ Hits         5589     5598       +9     
- Misses       1672     1674       +2     
- Partials      526      528       +2
Impacted Files Coverage Δ
parser.go 70.58% <ø> (ø) ⬆️
ast/ddl.go 80.44% <69.23%> (-0.1%) ⬇️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update a621a0f...ddfeae3. Read the comment docs.

@zuoRambo zuoRambo changed the title parser: fix alter_stmt order by syntaxFix parser: fix alter_stmt order by syntax Aug 27, 2019
ast/ddl.go Outdated Show resolved Hide resolved
parser.y Outdated Show resolved Hide resolved
parser.y Outdated Show resolved Hide resolved
parser.y Outdated Show resolved Hide resolved
parser.y Outdated Show resolved Hide resolved
parser.y Outdated Show resolved Hide resolved
Copy link
Contributor

@zier-one zier-one left a comment

Choose a reason for hiding this comment

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

LGTM

@zier-one
Copy link
Contributor

@tangenta PTAL

Copy link
Contributor

@tangenta tangenta left a comment

Choose a reason for hiding this comment

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

Rest LGTM

parser.y Outdated Show resolved Hide resolved
parser.y Outdated Show resolved Hide resolved
parser.y Outdated Show resolved Hide resolved
Copy link
Contributor

@tangenta tangenta left a comment

Choose a reason for hiding this comment

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

LGTM

@tangenta tangenta merged commit 736e807 into pingcap:master Aug 29, 2019
tiancaiamao pushed a commit to tiancaiamao/parser that referenced this pull request Apr 27, 2021
lyonzhi pushed a commit to lyonzhi/parser that referenced this pull request Apr 25, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants