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

executor: Use charset and collation from server vars for new schemas #27216

Merged
merged 7 commits into from
Oct 19, 2021

Conversation

dveeden
Copy link
Contributor

@dveeden dveeden commented Aug 13, 2021

What problem does this PR solve?

Issue Number: close #27214

Problem Summary:

CREATE SCHEMA should use the charset and collation from character_set_server and collation_server session/global vars if none are provided as part of the statement.

Check List

Tests

  • Unit test
  • Manual test (add detailed scripts or steps below)

Documentation

  • Affects user behaviors
  • Contains syntax changes
  • Contains variable changes
  • Contains experimental features
  • Changes MySQL compatibility

Release note

CREATE SCHEMA now uses `character_set_server` and `collation_server` for new schemas if none are provided as part of the statement

@ti-chi-bot
Copy link
Member

ti-chi-bot commented Aug 13, 2021

[REVIEW NOTIFICATION]

This pull request has been approved by:

  • lcwangchao
  • morgo

To complete the pull request process, please ask the reviewers in the list to review by filling /cc @reviewer in the comment.
After your PR has acquired the required number of LGTMs, you can assign this pull request to the committer in the list by filling /assign @committer in the comment to help you merge this pull request.

The full list of commands accepted by this bot can be found here.

Reviewer can indicate their review by submitting an approval review.
Reviewer can cancel approval by submitting a request changes review.

@ti-chi-bot ti-chi-bot added do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. release-note Denotes a PR that will be considered when it comes time to generate release notes. size/XS Denotes a PR that changes 0-9 lines, ignoring generated files. labels Aug 13, 2021
@dveeden
Copy link
Contributor Author

dveeden commented Aug 13, 2021

/cc @morgo

@ti-chi-bot ti-chi-bot requested a review from morgo August 13, 2021 12:40
@github-actions github-actions bot added the sig/execution SIG execution label Aug 13, 2021
@dveeden dveeden force-pushed the schema_collation__server_vars branch from d66c7b4 to f242071 Compare August 19, 2021 05:49
@ti-chi-bot ti-chi-bot added size/S Denotes a PR that changes 10-29 lines, ignoring generated files. and removed size/XS Denotes a PR that changes 0-9 lines, ignoring generated files. labels Aug 19, 2021
@dveeden dveeden force-pushed the schema_collation__server_vars branch from f242071 to ce42b95 Compare August 19, 2021 06:22
@ti-chi-bot ti-chi-bot added size/M Denotes a PR that changes 30-99 lines, ignoring generated files. and removed size/S Denotes a PR that changes 10-29 lines, ignoring generated files. labels Aug 19, 2021
@dveeden dveeden force-pushed the schema_collation__server_vars branch 2 times, most recently from b4d6dbb to b4eb4b2 Compare August 19, 2021 06:53
@dveeden
Copy link
Contributor Author

dveeden commented Aug 19, 2021

/run-check_dev_2

@dveeden dveeden force-pushed the schema_collation__server_vars branch 2 times, most recently from f8e2add to 7860de1 Compare August 19, 2021 08:31
@dveeden
Copy link
Contributor Author

dveeden commented Aug 19, 2021

/run-check_dev_2

@dveeden dveeden marked this pull request as ready for review August 19, 2021 08:55
@ti-chi-bot ti-chi-bot removed the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label Aug 19, 2021
@dveeden dveeden force-pushed the schema_collation__server_vars branch from 7860de1 to 5af1e1c Compare August 19, 2021 08:57
@ti-chi-bot
Copy link
Member

@morgo: Thanks for your review. The bot only counts approvals from reviewers and higher roles in list, but you're still welcome to leave your comments.

In response to this:

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the ti-community-infra/tichi repository.

@morgo morgo requested a review from bb7133 August 20, 2021 14:05
@morgo morgo added the sig/sql-infra SIG: SQL Infra label Aug 20, 2021
@morgo morgo self-requested a review August 20, 2021 14:58
@ti-chi-bot ti-chi-bot added the status/LGT1 Indicates that a PR has LGTM 1. label Aug 20, 2021
Copy link
Contributor

@mjonss mjonss left a comment

Choose a reason for hiding this comment

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

LGTM, just a question of more coverage in the test.

executor/ddl_test.go Show resolved Hide resolved
@dveeden dveeden force-pushed the schema_collation__server_vars branch from 5b867ab to 7ad5e69 Compare October 11, 2021 06:58
@dveeden
Copy link
Contributor Author

dveeden commented Oct 12, 2021

/uncc @coocood

@ti-chi-bot ti-chi-bot removed the request for review from coocood October 12, 2021 10:58
executor/ddl.go Outdated Show resolved Hide resolved
executor/ddl.go Outdated Show resolved Hide resolved
executor/ddl.go Outdated Show resolved Hide resolved
executor/ddl.go Outdated Show resolved Hide resolved
@ti-chi-bot ti-chi-bot added status/LGT2 Indicates that a PR has LGTM 2. and removed status/LGT1 Indicates that a PR has LGTM 1. labels Oct 18, 2021
@bb7133
Copy link
Member

bb7133 commented Oct 19, 2021

/merge

@ti-chi-bot
Copy link
Member

This pull request has been accepted and is ready to merge.

Commit hash: 308d098

@ti-chi-bot ti-chi-bot added the status/can-merge Indicates a PR has been approved by a committer. label Oct 19, 2021
@dveeden
Copy link
Contributor Author

dveeden commented Nov 23, 2021

/label needs-cherry-pick-5.2

ti-srebot pushed a commit to ti-srebot/tidb that referenced this pull request Nov 23, 2021
Signed-off-by: ti-srebot <ti-srebot@pingcap.com>
@ti-srebot
Copy link
Contributor

cherry pick to release-5.2 in PR #30077

@guo-shaoge guo-shaoge added the needs-cherry-pick-release-5.3 Type: Need cherry pick to release-5.3 label Feb 21, 2022
@ti-srebot
Copy link
Contributor

cherry pick to release-5.3 failed

@mjonss
Copy link
Contributor

mjonss commented Feb 21, 2022

cherry pick to release-5.3 failed

Because it already is included in release-5.3 :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
needs-cherry-pick-release-5.2 needs-cherry-pick-release-5.3 Type: Need cherry pick to release-5.3 release-note Denotes a PR that will be considered when it comes time to generate release notes. sig/execution SIG execution sig/sql-infra SIG: SQL Infra size/M Denotes a PR that changes 30-99 lines, ignoring generated files. status/can-merge Indicates a PR has been approved by a committer. status/LGT2 Indicates that a PR has LGTM 2.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

CREATE SCHEMA is not respecting the collation_server variable
8 participants