forked frompostgres/postgres
- Notifications
You must be signed in to change notification settings - Fork6
Commit461f479
committed
Correctly check updatability of columns targeted by INSERT...DEFAULT.
If a view has some updatable and some non-updatable columns, we failedto verify updatability of any columns for which an INSERT or UPDATEon the view explicitly specifies a DEFAULT item (unless the view hasa declared default for that column, which is rare anyway, and onewould almost certainly not write one for a non-updatable column).This would lead to an unexpected "attribute number N not found inview targetlist" error rather than the intended error.Per bug #18546 from Alexander Lakhin. This bug is old, so back-patchto all supported branches.Discussion:https://postgr.es/m/18546-84a292e759a9361d@postgresql.org1 parentc5321e9 commit461f479
File tree
3 files changed
+23
-10
lines changed- src
- backend/rewrite
- test/regress
- expected
- sql
3 files changed
+23
-10
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2914 | 2914 | | |
2915 | 2915 | | |
2916 | 2916 | | |
2917 | | - | |
| 2917 | + | |
2918 | 2918 | | |
2919 | 2919 | | |
2920 | 2920 | | |
| |||
3011 | 3011 | | |
3012 | 3012 | | |
3013 | 3013 | | |
| 3014 | + | |
| 3015 | + | |
| 3016 | + | |
3014 | 3017 | | |
3015 | 3018 | | |
3016 | 3019 | | |
| |||
3053 | 3056 | | |
3054 | 3057 | | |
3055 | 3058 | | |
3056 | | - | |
3057 | | - | |
3058 | | - | |
3059 | | - | |
3060 | | - | |
| 3059 | + | |
3061 | 3060 | | |
3062 | 3061 | | |
3063 | 3062 | | |
3064 | | - | |
| 3063 | + | |
3065 | 3064 | | |
3066 | 3065 | | |
| 3066 | + | |
| 3067 | + | |
| 3068 | + | |
| 3069 | + | |
| 3070 | + | |
| 3071 | + | |
| 3072 | + | |
| 3073 | + | |
| 3074 | + | |
| 3075 | + | |
| 3076 | + | |
| 3077 | + | |
| 3078 | + | |
3067 | 3079 | | |
3068 | 3080 | | |
3069 | 3081 | | |
| |||
3121 | 3133 | | |
3122 | 3134 | | |
3123 | 3135 | | |
3124 | | - | |
3125 | | - | |
3126 | | - | |
3127 | 3136 | | |
3128 | 3137 | | |
3129 | 3138 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1361 | 1361 | | |
1362 | 1362 | | |
1363 | 1363 | | |
| 1364 | + | |
| 1365 | + | |
| 1366 | + | |
1364 | 1367 | | |
1365 | 1368 | | |
1366 | 1369 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
665 | 665 | | |
666 | 666 | | |
667 | 667 | | |
| 668 | + | |
668 | 669 | | |
669 | 670 | | |
670 | 671 | | |
| |||
0 commit comments
Comments
(0)