- Notifications
You must be signed in to change notification settings - Fork4.9k
Commit3d3a81f
committed
Fix tuple_fraction calculation in generate_orderedappend_paths()
6b94e7a adjusted generate_orderedappend_paths() to consider fractionalpaths. However, it didn't manage to interpret the tuple_fraction valuecorrectly. According to the header comment of grouping_planner(), thetuple_fraction >= 1 specifies the absolute number of expected tuples. Thatnumber must be divided by the expected total number of tuples to get theactual fraction.Even though this is a bug fix, we don't backpatch it. The risks of the sideeffects of plan changes on stable branches are too high.Reported-by: Andrei Lepikhov <lepihov@gmail.com>Discussion:https://postgr.es/m/3ca271fa-ca5c-458c-8934-eb148622b270%40gmail.comAuthor: Andrei Lepikhov <lepihov@gmail.com>Reviewed-by: Junwang Zhao <zhjwpku@gmail.com>Reviewed-by: Alvaro Herrera <alvherre@alvh.no-ip.org>Reviewed-by: Tom Lane <tgl@sss.pgh.pa.us>1 parent12eee85 commit3d3a81f
File tree
3 files changed
+32
-1
lines changed- src
- backend/optimizer/path
- test/regress
- expected
- sql
3 files changed
+32
-1
lines changedLines changed: 11 additions & 1 deletion
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
1891 | 1891 |
| |
1892 | 1892 |
| |
1893 | 1893 |
| |
1894 |
| - | |
| 1894 | + | |
| 1895 | + | |
| 1896 | + | |
| 1897 | + | |
| 1898 | + | |
| 1899 | + | |
| 1900 | + | |
| 1901 | + | |
| 1902 | + | |
| 1903 | + | |
| 1904 | + | |
1895 | 1905 |
| |
1896 | 1906 |
| |
1897 | 1907 |
| |
|
Lines changed: 18 additions & 0 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
5260 | 5260 |
| |
5261 | 5261 |
| |
5262 | 5262 |
| |
| 5263 | + | |
| 5264 | + | |
| 5265 | + | |
| 5266 | + | |
| 5267 | + | |
| 5268 | + | |
| 5269 | + | |
| 5270 | + | |
| 5271 | + | |
| 5272 | + | |
| 5273 | + | |
| 5274 | + | |
| 5275 | + | |
| 5276 | + | |
| 5277 | + | |
| 5278 | + | |
| 5279 | + | |
| 5280 | + | |
5263 | 5281 |
| |
5264 | 5282 |
| |
5265 | 5283 |
| |
|
Lines changed: 3 additions & 0 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
1224 | 1224 |
| |
1225 | 1225 |
| |
1226 | 1226 |
| |
| 1227 | + | |
| 1228 | + | |
| 1229 | + | |
1227 | 1230 |
| |
1228 | 1231 |
| |
1229 | 1232 |
| |
|
0 commit comments
Comments
(0)