Note:
This topic has been translated from a Chinese forum by GPT and might contain errors.Original topic: 执行计划算子后面的数字代表什么意思
What do the numbers after the execution plan operators represent?
Note:
This topic has been translated from a Chinese forum by GPT and might contain errors.Original topic: 执行计划算子后面的数字代表什么意思
What do the numbers after the execution plan operators represent?
Got it. My understanding is that the number doesn’t have much significance when analyzing the execution plan and doesn’t need special attention.
The numbers following the execution plan operators basically indicate the execution order, and you also need to consider the keywords following the node IDs. Build always executes before Probe, and Build always appears before Probe. You can refer to the official documentation for a description of the execution order of operators:
This post also doesn’t explain the meaning of the numbers clearly.
If it’s not something to be concerned about, why has it been present in older versions like tidb3 and tidb4?
Borrowing this post to ask a question:
I can see numbers like 20, 21, 9, 19, 18, etc. below the execution plan.
+------------------------------+----------+-----------+---------------+------------------------------------------------------------------------------------------------------------------------+
| id | estRows | task | access object | operator info |
+------------------------------+----------+-----------+---------------+------------------------------------------------------------------------------------------------------------------------+
| StreamAgg_20 | 1.00 | root | | funcs:count(Column#13)->Column#11 |
| └─TableReader_21 | 1.00 | root | | data:StreamAgg_9 |
| └─StreamAgg_9 | 1.00 | cop[tikv] | | funcs:count(1)->Column#13 |
| └─Selection_19 | 250.00 | cop[tikv] | | ge(bikeshare.trips.start_date, 2017-07-01 00:00:00.000000), le(bikeshare.trips.start_date, 2017-07-01 23:59:59.000000) |
| └─TableFullScan_18 | 10000.00 | cop[tikv] | table:trips | keep order:false, stats:pseudo |
+------------------------------+----------+-----------+---------------+------------------------------------------------------------------------------------------------------------------------+
5 rows in set (0.00 sec)