aboutsummaryrefslogtreecommitdiff
path: root/src/backend/access/gist/gistproc.c
diff options
context:
space:
mode:
authorTom Lane <tgl@sss.pgh.pa.us>2009-09-12 00:04:59 +0000
committerTom Lane <tgl@sss.pgh.pa.us>2009-09-12 00:04:59 +0000
commitd5a4b69c3a0d2668fa6098c73be7b6f0036bb642 (patch)
treef807e00ab424c10166007bb04b9a97ab2d0c4c75 /src/backend/access/gist/gistproc.c
parent8c5463a51176c8d2a01fcf154d7ac33fa9a74f6a (diff)
downloadpostgresql-d5a4b69c3a0d2668fa6098c73be7b6f0036bb642.tar.gz
postgresql-d5a4b69c3a0d2668fa6098c73be7b6f0036bb642.zip
Fix assertion failure when a SELECT DISTINCT ON expression is volatile.
In this case we generate two PathKey references to the expression (one for DISTINCT and one for ORDER BY) and they really need to refer to the same EquivalenceClass. However get_eclass_for_sort_expr was being overly paranoid and creating two different EC's. Correct behavior is to use the SortGroupRef index to decide whether two references to volatile expressions that are equal() (ie textually equivalent) should be considered the same. Backpatch to 8.4. Possibly this should be changed in 8.3 as well, but I'll refrain in the absence of evidence of a visible failure in that branch. Per bug #5049.
Diffstat (limited to 'src/backend/access/gist/gistproc.c')
0 files changed, 0 insertions, 0 deletions