-
Notifications
You must be signed in to change notification settings - Fork 1.2k
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
Update description on rule based index selection #6815
Update description on rule based index selection #6815
Conversation
[REVIEW NOTIFICATION] This pull request has been approved by:
To complete the pull request process, please ask the reviewers in the list to review by filling The full list of commands accepted by this bot can be found here. Reviewer can indicate their review by submitting an approval review. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@xuyifangreeneyes PTAL
Co-authored-by: Grace Cai <[email protected]>
Co-authored-by: Grace Cai <[email protected]>
Co-authored-by: Grace Cai <[email protected]>
- 索引的列涵盖了多少访问条件。“访问条件”指的是可以转化为某列范围的 `where` 条件,如果某个索引的列集合涵盖的访问条件越多,那么它在这个维度上更优。 | ||
|
||
对于这三种维度,如果某个索引 `idx_a` 在**三个维度上都不比 `idx_b` 差**,且**有一个维度比 `idx_b` 好**,那么就会优先选择 `idx_a`。 | ||
- 选择该索引读表时,是否需要回表(即该索引生成的计划是 IndexReader 还是 IndexLookupReader)。不用回表的索引在这个维度上优于需要回表的索引。如果均需要回表,则比较索引的列涵盖了多少过滤条件。过滤条件指的是可以根据索引判断的 `where` 条件。如果某个索引的列集合涵盖的访问条件越多,则回表数量越少,那么它在这个维度上越优。 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
“访问条件”的双引号需要去掉吗
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We add two examples for the warning message output.
rest LGTM
So what changes should be made to this doc PR? |
…angreeneyes/docs-cn into rule-based-index-selection
I have added the two examples in this PR, please take a look. |
@winoros: 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. |
@Rick-lee01 PTAL |
Co-authored-by: TomShawn <[email protected]>
Co-authored-by: TomShawn <[email protected]>
Co-authored-by: TomShawn <[email protected]>
Co-authored-by: TomShawn <[email protected]>
Co-authored-by: TomShawn <[email protected]>
Co-authored-by: TomShawn <[email protected]>
Co-authored-by: TomShawn <[email protected]>
Co-authored-by: TomShawn <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
/merge |
@TomShawn: 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. |
/remove-status LGT1 |
/merge |
This pull request has been accepted and is ready to merge. Commit hash: 4613bdb
|
What is changed, added or deleted? (Required)
Update description on rule based index selection.
Closed pingcap/tidb#27230
Which TiDB version(s) do your changes apply to? (Required)
What is the related PR or file link(s)?
Do your changes match any of the following descriptions?