Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
Skip to content

Commit 5577ca5

Browse files
committed
Remove bogus entries in gist point_ops operator class.
These entries could never be matched to an index clause because they don't have the index datatype on the left-hand side of the operator. (Their commutators are in the opclass, which is sensible, but that doesn't mean these operators should be.) Spotted by a test that I recently added to opr_sanity to catch exactly this type of thinko. AFAICT there is no code in gistproc.c that is specifically meant to cover these cases, so nothing to remove at that level.
1 parent dd45d3a commit 5577ca5

File tree

3 files changed

+3
-12
lines changed

3 files changed

+3
-12
lines changed

src/include/catalog/catversion.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -53,6 +53,6 @@
5353
*/
5454

5555
/* yyyymmddN */
56-
#define CATALOG_VERSION_NO 201112171
56+
#define CATALOG_VERSION_NO 201112172
5757

5858
#endif

src/include/catalog/pg_amop.h

-3
Original file line numberDiff line numberDiff line change
@@ -605,11 +605,8 @@ DATA(insert ( 1029 600 600 5 s 508 783 0 ));
605605
DATA(insert ( 1029 600 600 10 s 509 783 0 ));
606606
DATA(insert ( 1029 600 600 6 s 510 783 0 ));
607607
DATA(insert ( 1029 600 600 15 o 517 783 1970 ));
608-
DATA(insert ( 1029 603 600 27 s 433 783 0 ));
609608
DATA(insert ( 1029 600 603 28 s 511 783 0 ));
610-
DATA(insert ( 1029 604 600 47 s 757 783 0 ));
611609
DATA(insert ( 1029 600 604 48 s 756 783 0 ));
612-
DATA(insert ( 1029 718 600 67 s 759 783 0 ));
613610
DATA(insert ( 1029 600 718 68 s 758 783 0 ));
614611

615612

src/test/regress/expected/opr_sanity.out

+2-8
Original file line numberDiff line numberDiff line change
@@ -1041,11 +1041,8 @@ ORDER BY 1, 2, 3;
10411041
783 | 15 | <->
10421042
783 | 16 | @>
10431043
783 | 18 | =
1044-
783 | 27 | @>
10451044
783 | 28 | <@
1046-
783 | 47 | @>
10471045
783 | 48 | <@
1048-
783 | 67 | @>
10491046
783 | 68 | <@
10501047
2742 | 1 | &&
10511048
2742 | 1 | @@
@@ -1068,7 +1065,7 @@ ORDER BY 1, 2, 3;
10681065
4000 | 12 | <=
10691066
4000 | 14 | >=
10701067
4000 | 15 | >
1071-
(58 rows)
1068+
(55 rows)
10721069

10731070
-- Check that all opclass search operators have selectivity estimators.
10741071
-- This is not absolutely required, but it seems a reasonable thing
@@ -1105,10 +1102,7 @@ WHERE NOT EXISTS(SELECT 1 FROM pg_opclass AS p2
11051102
AND binary_coercible(p2.opcintype, p1.amoplefttype));
11061103
amopfamily | amopstrategy | amopopr
11071104
------------+--------------+---------
1108-
1029 | 27 | 433
1109-
1029 | 47 | 757
1110-
1029 | 67 | 759
1111-
(3 rows)
1105+
(0 rows)
11121106

11131107
-- Operators that are primary members of opclasses must be immutable (else
11141108
-- it suggests that the index ordering isn't fixed). Operators that are

0 commit comments

Comments
 (0)