- Notifications
You must be signed in to change notification settings - Fork28
Commit391159e
committed
Partially revert commit3d3bf62.
On reflection, the pre-existing logic in ANALYZE is specifically meant tocompare the frequency of a candidate MCV against the estimated frequency ofa random distinct value across the whole table. The change to compare itagainst the average frequency of values actually seen in the sample doesn'tseem very principled, and if anything it would make us less likely not morelikely to consider a value an MCV. So revert that, but keep the aspect ofconsidering only nonnull values, which definitely is correct.In passing, rename the local variables in these stanzas to"ndistinct_table", to avoid confusion with the "ndistinct" that appears atan outer scope in compute_scalar_stats.1 parentc9ff752 commit391159e
1 file changed
+10
-6
lines changedLines changed: 10 additions & 6 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
2133 | 2133 |
| |
2134 | 2134 |
| |
2135 | 2135 |
| |
2136 |
| - | |
2137 |
| - | |
| 2136 | + | |
2138 | 2137 |
| |
2139 | 2138 |
| |
2140 | 2139 |
| |
| 2140 | + | |
| 2141 | + | |
| 2142 | + | |
2141 | 2143 |
| |
2142 |
| - | |
| 2144 | + | |
2143 | 2145 |
| |
2144 | 2146 |
| |
2145 | 2147 |
| |
| |||
2493 | 2495 |
| |
2494 | 2496 |
| |
2495 | 2497 |
| |
2496 |
| - | |
2497 |
| - | |
| 2498 | + | |
2498 | 2499 |
| |
2499 | 2500 |
| |
2500 | 2501 |
| |
2501 | 2502 |
| |
| 2503 | + | |
| 2504 | + | |
| 2505 | + | |
2502 | 2506 |
| |
2503 |
| - | |
| 2507 | + | |
2504 | 2508 |
| |
2505 | 2509 |
| |
2506 | 2510 |
| |
|
0 commit comments
Comments
(0)