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

Commit7074337

Browse files
Refine nbtree = redundancy preprocessing comment.
Spell out how a = key associated with a SAOP array renders a > keyagainst the same index column redundant at the relevant point inside_bt_preprocess_keys.Follow-up to commit5bf748b.
1 parent94131cd commit7074337

File tree

1 file changed

+8
-2
lines changed

1 file changed

+8
-2
lines changed

‎src/backend/access/nbtree/nbtutils.c

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2668,8 +2668,14 @@ _bt_preprocess_keys(IndexScanDesc scan)
26682668

26692669
/*
26702670
* If = has been specified, all other keys can be eliminated as
2671-
* redundant. If we have a case like key = 1 AND key > 2, we can
2672-
* set qual_ok to false and abandon further processing.
2671+
* redundant. Note that this is no less true if the = key is
2672+
* SEARCHARRAY; the only real difference is that the inequality
2673+
* key _becomes_ redundant by making _bt_compare_scankey_args
2674+
* eliminate the subset of elements that won't need to be matched.
2675+
*
2676+
* If we have a case like "key = 1 AND key > 2", we set qual_ok to
2677+
* false and abandon further processing. We'll do the same thing
2678+
* given a case like "key IN (0, 1) AND key > 2".
26732679
*
26742680
* We also have to deal with the case of "key IS NULL", which is
26752681
* unsatisfiable in combination with any other index condition. By

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp