[SERVER-71803] Explain displays incorrect cost for some ABT nodes Created: 02/Dec/22 Updated: 27/Oct/23 Resolved: 02/Feb/23 |
|
| Status: | Closed |
| Project: | Core Server |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major - P3 |
| Reporter: | Alexander Ignatyev | Assignee: | Svilen Mihaylov (Inactive) |
| Resolution: | Works as Designed | Votes: | 0 |
| Labels: | explain | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Issue Links: |
|
|||||||||||||||||||||||||||||||||||||||
| Assigned Teams: |
Query Optimization
|
|||||||||||||||||||||||||||||||||||||||
| Operating System: | ALL | |||||||||||||||||||||||||||||||||||||||
| Steps To Reproduce: |
The code above displays the following stats: PhysicalScan
However, for physicalScan we would expect localCost = scanStartupCost + scanIncrementalCost * adjustedCE = 10.5 + 2.7*1000 = 2710.5 but got 4640.8 instead. Filter
For filter's localCost we would expect localCost = filterStartupCost + filterIncrementalCost*adjustedCE = 30.3 + 1.9 * 1000 = 1930.3 but we got 4640.8 instead for the cost we would expect and we got 4640.8 as expected. The fact that filter localCost includes PhysicalScan;'s localCost might be treated as expected behaviour, since the filter's cost includes its child's cost in the current implementaion of the CostEstimator, however, it does not look convinient. |
|||||||||||||||||||||||||||||||||||||||
| Sprint: | QO 2023-01-09, QO 2023-01-23 | |||||||||||||||||||||||||||||||||||||||
| Participants: | ||||||||||||||||||||||||||||||||||||||||
| Description |
|
If an ABT node is an inner node of a group in the Bonsai, instead of its cost explain display the cost of the root node of the group. |