forked frompostgres/postgres
- Notifications
You must be signed in to change notification settings - Fork6
Commitd6f549d
committed
Fix pg_dump's failure to honor dependencies of SQL functions.
A new-style SQL function can contain a parse-time dependencyon a unique index, much as views and matviews can (such casesarise from GROUP BY and ON CONFLICT clauses, for example).To dump and restore such a function successfully, pg_dump mustpostpone the function until after the unique index is created,which will happen in the post-data part of the dump. Thereforewe have to remove the normal constraint that functions aredumped in pre-data. Add code similar to the existing logicthat handles this for matviews. I added test cases for bothas well, since code coverage tests showed that we weren'ttesting the matview logic.Per report from Sami Imseih. Back-patch to v14 wherenew-style SQL functions came in.Discussion:https://postgr.es/m/2C1933AB-C2F8-499B-9D18-4AC1882256A0@amazon.com1 parent3d8aefe commitd6f549d
File tree
4 files changed
+89
-1
lines changed- src/bin/pg_dump
- t
4 files changed
+89
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
6073 | 6073 | | |
6074 | 6074 | | |
6075 | 6075 | | |
| 6076 | + | |
6076 | 6077 | | |
6077 | 6078 | | |
6078 | 6079 | | |
| |||
6303 | 6304 | | |
6304 | 6305 | | |
6305 | 6306 | | |
| 6307 | + | |
6306 | 6308 | | |
6307 | 6309 | | |
6308 | 6310 | | |
| |||
12691 | 12693 | | |
12692 | 12694 | | |
12693 | 12695 | | |
12694 | | - | |
| 12696 | + | |
| 12697 | + | |
12695 | 12698 | | |
12696 | 12699 | | |
12697 | 12700 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
207 | 207 | | |
208 | 208 | | |
209 | 209 | | |
| 210 | + | |
210 | 211 | | |
211 | 212 | | |
212 | 213 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
866 | 866 | | |
867 | 867 | | |
868 | 868 | | |
| 869 | + | |
| 870 | + | |
| 871 | + | |
| 872 | + | |
| 873 | + | |
| 874 | + | |
| 875 | + | |
| 876 | + | |
| 877 | + | |
| 878 | + | |
| 879 | + | |
| 880 | + | |
| 881 | + | |
| 882 | + | |
| 883 | + | |
| 884 | + | |
| 885 | + | |
| 886 | + | |
| 887 | + | |
| 888 | + | |
| 889 | + | |
| 890 | + | |
869 | 891 | | |
870 | 892 | | |
871 | 893 | | |
| |||
1060 | 1082 | | |
1061 | 1083 | | |
1062 | 1084 | | |
| 1085 | + | |
| 1086 | + | |
| 1087 | + | |
| 1088 | + | |
| 1089 | + | |
| 1090 | + | |
| 1091 | + | |
| 1092 | + | |
| 1093 | + | |
| 1094 | + | |
| 1095 | + | |
| 1096 | + | |
| 1097 | + | |
| 1098 | + | |
| 1099 | + | |
| 1100 | + | |
| 1101 | + | |
| 1102 | + | |
| 1103 | + | |
| 1104 | + | |
| 1105 | + | |
| 1106 | + | |
1063 | 1107 | | |
1064 | 1108 | | |
1065 | 1109 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1957 | 1957 | | |
1958 | 1958 | | |
1959 | 1959 | | |
| 1960 | + | |
| 1961 | + | |
| 1962 | + | |
| 1963 | + | |
| 1964 | + | |
| 1965 | + | |
| 1966 | + | |
| 1967 | + | |
| 1968 | + | |
| 1969 | + | |
| 1970 | + | |
| 1971 | + | |
| 1972 | + | |
| 1973 | + | |
| 1974 | + | |
| 1975 | + | |
| 1976 | + | |
| 1977 | + | |
| 1978 | + | |
| 1979 | + | |
| 1980 | + | |
1960 | 1981 | | |
1961 | 1982 | | |
1962 | 1983 | | |
| |||
2169 | 2190 | | |
2170 | 2191 | | |
2171 | 2192 | | |
| 2193 | + | |
| 2194 | + | |
| 2195 | + | |
| 2196 | + | |
| 2197 | + | |
| 2198 | + | |
| 2199 | + | |
| 2200 | + | |
| 2201 | + | |
| 2202 | + | |
| 2203 | + | |
| 2204 | + | |
| 2205 | + | |
| 2206 | + | |
| 2207 | + | |
| 2208 | + | |
| 2209 | + | |
| 2210 | + | |
| 2211 | + | |
2172 | 2212 | | |
2173 | 2213 | | |
2174 | 2214 | | |
| |||
0 commit comments
Comments
(0)