MDEV-39602: Document the join_type enumeration#5182
MDEV-39602: Document the join_type enumeration#5182DaveGosselin-MariaDB wants to merge 1 commit into
Conversation
Replace the one line comment on join_type in sql_select.h with a comment on each value. Each comment explains what the access method is, the conditions under which the optimizer chooses it, and what EXPLAIN will show for it.
There was a problem hiding this comment.
Code Review
This pull request adds detailed documentation comments to the join_type enum in sql/sql_select.h, explaining the meaning and EXPLAIN output representation of each join type. The review feedback suggests minor grammatical improvements to resolve comma splices in the newly added comments for JT_SYSTEM and JT_ALL to enhance readability.
Important
The consumer version of Gemini Code Assist on GitHub is being sunset. Starting June 18, 2026, new organization installations will be blocked, and all code review activity will officially cease on July 17, 2026.
For more details on the timeline and next steps, please review the Help Documentation.
| row count statistics. The row is read once and kept in the record | ||
| buffer for the rest of the query, the remaining conditions treat | ||
| its columns as constants, and the table becomes part of the | ||
| constant prefix of the join order, so the join order search only | ||
| covers the remaining tables. |
There was a problem hiding this comment.
This sentence contains a comma splice ('the query, the remaining conditions...'). Splitting it into two sentences improves readability and grammatical correctness.
row count statistics. The row is read once and kept in the record
buffer for the rest of the query. The remaining conditions treat
its columns as constants, and the table becomes part of the
constant prefix of the join order, so the join order search only
covers the remaining tables.| alternatives. At execution this type is also used for range and | ||
| index merge access; the JOIN_TAB keeps JT_ALL, the attached | ||
| quick select supplies the actual access method, and the EXPLAIN | ||
| type is derived from the quick select. A "Range checked for |
There was a problem hiding this comment.
This sentence contains a comma splice ('keeps JT_ALL, the attached quick select...'). Using 'while' to connect the clauses makes the sentence flow better and improves grammatical correctness.
alternatives. At execution this type is also used for range and
index merge access; the JOIN_TAB keeps JT_ALL, while the attached
quick select supplies the actual access method and the EXPLAIN
type is derived from the quick select. A "Range checked for
Replace the one line comment on join_type in sql_select.h with a comment on each value. Each comment explains what the access method is, the conditions under which the optimizer chooses it, and what EXPLAIN will show for it.