|
7 | 7 | *
|
8 | 8 | *
|
9 | 9 | * IDENTIFICATION
|
10 |
| - * $Header: /cvsroot/pgsql/src/backend/optimizer/util/pathnode.c,v 1.26 1999/02/1114:59:02 momjian Exp $ |
| 10 | + * $Header: /cvsroot/pgsql/src/backend/optimizer/util/pathnode.c,v 1.27 1999/02/1116:09:41 momjian Exp $ |
11 | 11 | *
|
12 | 12 | *-------------------------------------------------------------------------
|
13 | 13 | */
|
@@ -194,9 +194,9 @@ better_path(Path *new_path, List *unique_paths, bool *is_new)
|
194 | 194 | * Replace pathkeys that match exactly, (1,2), (1,2).
|
195 | 195 | * Replace pathkeys (1,2) with (1,2,3) if the latter is not
|
196 | 196 | * more expensive and replace unordered path with ordered
|
197 |
| - * path if it is not more expensive. |
| 197 | + * path if it is not more expensive. Favor sorted keys |
| 198 | + * over unsorted keys in the same way. |
198 | 199 | */
|
199 |
| - |
200 | 200 | /* same keys, and new is cheaper, use it */
|
201 | 201 | if ((longer_key==0&&more_sort==0&&
|
202 | 202 | new_path->path_cost<path->path_cost)||
|
|