Skip to content

Commit

Permalink
Apply suggestions from code review
Browse files Browse the repository at this point in the history
Co-authored-by: TomShawn <41534398+TomShawn@users.noreply.github.com>
  • Loading branch information
Liuxiaozhen12 and TomShawn authored Aug 20, 2021
1 parent 84c19ab commit 27ea66c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions choose-index.md
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ TiDB selects indexes based on rules or cost. The based rules include pre-rules a

#### Pre-rules

TiDB uses the following heuristic pre rules to select indexes:
TiDB uses the following heuristic pre-rules to select indexes:

+ Rule 1: If an index satisfies "unique index with full match + no need to retrieve rows from a table (which means that the plan generated by the index is the IndexReader operator)", TiDB directly selects this index.

Expand Down Expand Up @@ -105,7 +105,7 @@ mysql> SHOW WARNINGS;
1 row in set (0.00 sec)
```

### Selection based on cost estimation
### Cost estimation-based selection

After using the skyline-pruning rule to rule out inappropriate indexes, the selection of indexes is based entirely on the cost estimation. The cost estimation of accessing tables requires the following considerations:

Expand Down

0 comments on commit 27ea66c

Please sign in to comment.