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

Allow SELECT options in any order #6082

Merged
merged 3 commits into from
Apr 20, 2020

Conversation

systay
Copy link
Collaborator

@systay systay commented Apr 17, 2020

Makes it possible for options such as DISTINCT,SQL_CACHE and STRAIGHT_JOIN
to be entered in any order. This is to follow MySQLs behaviour.

Also adds one more new SELECT option - sql_calc_found_rows

Signed-off-by: Andres Taylor [email protected]

@systay systay requested a review from sougou as a code owner April 17, 2020 14:59
@systay systay requested a review from saifalharthi April 18, 2020 18:17
{
$$ = []string{$1, $2}
}
| select_option select_option select_option //TODO I tried and got 'conflicts: 8 shift/reduce'
Copy link
Contributor

Choose a reason for hiding this comment

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

Is this resolved?

Copy link
Contributor

@saifalharthi saifalharthi left a comment

Choose a reason for hiding this comment

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

LGTM

@@ -398,9 +400,10 @@ stream_statement:

// base_select is an unparenthesized SELECT with no order by clause or beyond.
base_select:
SELECT comment_opt cache_opt distinct_opt straight_join_opt select_expression_list from_opt where_expression_opt group_by_opt having_opt
// 1 2 3 4 5 6 7 8
Copy link
Member

Choose a reason for hiding this comment

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

can be removed.

systay added 3 commits April 20, 2020 11:00
Makes it possible for options such as DISTINCT,SQL_CACHE and STRAIGHT_JOIN
to be entered in any order. This is to follow MySQLs behaviour.

Signed-off-by: Andres Taylor <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants