forked frompostgres/postgres
- Notifications
You must be signed in to change notification settings - Fork6
Commit3f244d0
committed
Make new GENERATED-expressions code more bulletproof.
In commit8bf6ec3 I assumed that no code path could reachExecGetExtraUpdatedCols without having gone throughExecInitStoredGenerated. That turns out not to be the case inlogical replication: if there's an ON UPDATE trigger on the targettable, trigger.c will call this code before anybody has set up itsgenerated columns. Having seen that, I don't have a lot of faith inthere not being other such paths. ExecGetExtraUpdatedCols can callExecInitStoredGenerated for itself, as long as we are willing toassume that it is only called in CMD_UPDATE operations, which onthe whole seems like a safer leap of faith.Per report from Vitaly Davydov.Discussion:https://postgr.es/m/d259d69652b8c2ff50e14cda3c236c7f@postgrespro.ru1 parent1334b79 commit3f244d0
File tree
4 files changed
+50
-17
lines changed- src
- backend/executor
- include/executor
- test/subscription/t
4 files changed
+50
-17
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
52 | 52 | | |
53 | 53 | | |
54 | 54 | | |
| 55 | + | |
55 | 56 | | |
56 | 57 | | |
57 | 58 | | |
| |||
1342 | 1343 | | |
1343 | 1344 | | |
1344 | 1345 | | |
1345 | | - | |
1346 | | - | |
1347 | | - | |
1348 | | - | |
1349 | | - | |
1350 | | - | |
1351 | | - | |
1352 | | - | |
1353 | | - | |
| 1346 | + | |
| 1347 | + | |
| 1348 | + | |
1354 | 1349 | | |
1355 | 1350 | | |
1356 | 1351 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
360 | 360 | | |
361 | 361 | | |
362 | 362 | | |
363 | | - | |
| 363 | + | |
364 | 364 | | |
365 | 365 | | |
366 | 366 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
15 | 15 | | |
16 | 16 | | |
17 | 17 | | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
18 | 22 | | |
19 | 23 | | |
20 | 24 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
25 | 25 | | |
26 | 26 | | |
27 | 27 | | |
28 | | - | |
| 28 | + | |
29 | 29 | | |
30 | 30 | | |
31 | 31 | | |
| |||
55 | 55 | | |
56 | 56 | | |
57 | 57 | | |
58 | | - | |
59 | | - | |
60 | | - | |
61 | | - | |
62 | | - | |
63 | | - | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
| 77 | + | |
| 78 | + | |
| 79 | + | |
| 80 | + | |
| 81 | + | |
| 82 | + | |
| 83 | + | |
| 84 | + | |
| 85 | + | |
| 86 | + | |
| 87 | + | |
| 88 | + | |
| 89 | + | |
| 90 | + | |
| 91 | + | |
| 92 | + | |
| 93 | + | |
| 94 | + | |
| 95 | + | |
| 96 | + | |
| 97 | + | |
64 | 98 | | |
65 | 99 | | |
0 commit comments
Comments
(0)