> > Prevent sorting if result is already sorted
Bruce Momjian <bruce@momjian.us>
> > Prevent sorting if result is already sorted > > > > was implemented by Jan Wieck. > > His work is for ascending order cases. > > > > Here is a patch to prevent sorting also in descending > > order cases. > > Because I had already changed _bt_first() to position > > backward correctly before v6.5,this patch would work. > > Hiroshi Inoue Inoue@tpf.co.jp
Files
| Path | Change | +/− |
|---|---|---|
| src/backend/commands/explain.c | modified | +3 −1 |
| src/backend/executor/nodeIndexscan.c | modified | +12 −1 |
| src/backend/nodes/copyfuncs.c | modified | +2 −1 |
| src/backend/nodes/equalfuncs.c | modified | +4 −1 |
| src/backend/nodes/outfuncs.c | modified | +2 −1 |
| src/backend/nodes/readfuncs.c | modified | +6 −1 |
| src/backend/optimizer/plan/createplan.c | modified | +2 −1 |
| src/backend/optimizer/plan/planner.c | modified | +45 −20 |
| src/include/nodes/plannodes.h | modified | +2 −1 |