pg_plan_advice: DO_NOT_SCAN is a simple tag, not a generic one.
Robert Haas <rhaas@postgresql.org>
pg_plan_advice: DO_NOT_SCAN is a simple tag, not a generic one. Generic tags allow sublists, e.g. MERGE_JOIN((x y)), but simple tags do not, e.g. SEQ_SCAN(x) is valid but SEQ_SCAN((x)) is not. DO_NOT_SCAN was intended to be simple tag, but was accidentally implemented as a generic one. This could result in assertion failures. Repair. Reported-by: Nikita Kalinin <n.kalinin@postgrespro.ru> Analyzed-by: Tender Wang <tndrwang@gmail.com> Analyzed-by: Ayush Tiwari <ayushtiwari.slg01@gmail.com> Discussion: http://postgr.es/m/19493-5878eac7a2525c23@postgresql.org
Files
| Path | Change | +/− |
|---|---|---|
| contrib/pg_plan_advice/expected/syntax.out | modified | +3 −0 |
| contrib/pg_plan_advice/pgpa_parser.y | modified | +2 −0 |
| contrib/pg_plan_advice/pgpa_scanner.l | modified | +2 −1 |
| contrib/pg_plan_advice/sql/syntax.sql | modified | +1 −0 |
Discussion
- BUG #19493: Assertion failure in pg_plan_advice with EXISTS subquery and DO_NOT_SCAN advice 11 messages · 2026-05-26 → 2026-05-29