Fix EXPLAIN ANALYZE bug noted by Wiebe Cazemier: although we were
Tom Lane <tgl@sss.pgh.pa.us>
Fix EXPLAIN ANALYZE bug noted by Wiebe Cazemier: although we were properly advancing the CommandCounter between multiple sub-queries generated by rules, we forgot to update the snapshot being used, so that the successive sub-queries didn't actually see each others' results. This is still not *exactly* like the semantics of normal execution of the same queries, in that we don't take new transaction snapshots and hence don't see changes from concurrently committed commands, but I think that's OK and probably even preferable for EXPLAIN ANALYZE.
Files
| Path | Change | +/− |
|---|---|---|
| src/backend/commands/explain.c | modified | +10 −1 |
| src/backend/commands/prepare.c | modified | +10 −1 |