When index recurses to a partition, map columns numbers
Alvaro Herrera <alvherre@alvh.no-ip.org>
When index recurses to a partition, map columns numbers Two out of three code paths were mapping column numbers correctly if a partition had different column numbers than parent table, but the most commonly used one (recursing in CREATE INDEX to a new index on a partition) failed to map attribute numbers in expressions. Oddly enough, attnums in WHERE clauses are already handled correctly everywhere. Reported-by: Amit Langote Author: Amit Langote Discussion: https://postgr.es/m/dce1fda4-e0f0-94c9-6abb-f5956a98c057@lab.ntt.co.jp Reviewed-by: Álvaro Herrera
Files
| Path | Change | +/− |
|---|---|---|
| src/backend/commands/indexcmds.c | modified | +25 −0 |
| src/test/regress/expected/indexing.out | modified | +10 −6 |
| src/test/regress/sql/indexing.sql | modified | +1 −0 |
Discussion
- bug with expression index on partition 7 messages · 2018-06-21 → 2018-06-25