Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commitb67ad04

Browse files
committed
Improve commentary in match_pathkeys_to_index().
For a little while there I thought match_pathkeys_to_index() was brokenbecause it wasn't trying to match index columns to pathkeys in order.Actually that's correct, because GiST can support ordering operatorson any random collection of index columns, but it sure needs a comment.
1 parentdd4134e commitb67ad04

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

‎src/backend/optimizer/path/indxpath.c

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2174,6 +2174,13 @@ match_pathkeys_to_index(IndexOptInfo *index, List *pathkeys,
21742174
if (!bms_equal(member->em_relids,index->rel->relids))
21752175
continue;
21762176

2177+
/*
2178+
* We allow any column of the index to match each pathkey; they
2179+
* don't have to match left-to-right as you might expect. This
2180+
* is correct for GiST, which is the sole existing AM supporting
2181+
* amcanorderbyop. We might need different logic in future for
2182+
* other implementations.
2183+
*/
21772184
for (indexcol=0;indexcol<index->ncolumns;indexcol++)
21782185
{
21792186
Expr*expr;

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp