forked frompostgres/postgres
- Notifications
You must be signed in to change notification settings - Fork6
Commitce95c54
committed
Fix pg_statio_all_tables view for multiple TOAST indexes.
A TOAST table can normally have only one index, but there are cornercases where it has more; for example, transiently during REINDEXCONCURRENTLY. In such a case, the pg_statio_all_tables view producedmultiple rows for the owning table, one per TOAST index. Refactor theview to avoid that, instead summing the stats across all the indexes,as we do for regular table indexes.While this has been wrong for a long time, back-patching seems unwisedue to the difficulty of putting a system view change into backbranches.Andrei Zubkov, tweaked a bit by meDiscussion:https://postgr.es/m/acefef4189706971fc475f912c1afdab1c48d627.camel@moonset.ru1 parent7dac614 commitce95c54
File tree
3 files changed
+34
-20
lines changed- src
- backend/catalog
- include/catalog
- test/regress/expected
3 files changed
+34
-20
lines changedLines changed: 20 additions & 11 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
727 | 727 |
| |
728 | 728 |
| |
729 | 729 |
| |
730 |
| - | |
731 |
| - | |
732 |
| - | |
| 730 | + | |
| 731 | + | |
733 | 732 |
| |
734 | 733 |
| |
735 | 734 |
| |
736 |
| - | |
737 |
| - | |
738 |
| - | |
| 735 | + | |
| 736 | + | |
739 | 737 |
| |
740 |
| - | |
741 |
| - | |
742 |
| - | |
| 738 | + | |
743 | 739 |
| |
744 |
| - | |
745 |
| - | |
| 740 | + | |
| 741 | + | |
| 742 | + | |
| 743 | + | |
| 744 | + | |
| 745 | + | |
| 746 | + | |
| 747 | + | |
| 748 | + | |
| 749 | + | |
| 750 | + | |
| 751 | + | |
| 752 | + | |
| 753 | + | |
| 754 | + | |
746 | 755 |
| |
747 | 756 |
| |
748 | 757 |
| |
|
Lines changed: 1 addition & 1 deletion
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
53 | 53 |
| |
54 | 54 |
| |
55 | 55 |
| |
56 |
| - | |
| 56 | + | |
57 | 57 |
| |
58 | 58 |
|
Lines changed: 13 additions & 8 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
2269 | 2269 |
| |
2270 | 2270 |
| |
2271 | 2271 |
| |
2272 |
| - | |
2273 |
| - | |
| 2272 | + | |
| 2273 | + | |
2274 | 2274 |
| |
2275 | 2275 |
| |
2276 |
| - | |
2277 |
| - | |
| 2276 | + | |
| 2277 | + | |
2278 | 2278 |
| |
2279 |
| - | |
2280 | 2279 |
| |
2281 |
| - | |
2282 | 2280 |
| |
2283 |
| - | |
2284 |
| - | |
| 2281 | + | |
| 2282 | + | |
| 2283 | + | |
| 2284 | + | |
| 2285 | + | |
| 2286 | + | |
| 2287 | + | |
| 2288 | + | |
| 2289 | + | |
2285 | 2290 |
| |
2286 | 2291 |
| |
2287 | 2292 |
| |
|
0 commit comments
Comments
(0)