diff options
Diffstat (limited to 'src/test')
| -rw-r--r-- | src/test/regress/expected/opr_sanity.out | 7 | ||||
| -rw-r--r-- | src/test/regress/sql/opr_sanity.sql | 7 |
2 files changed, 6 insertions, 8 deletions
diff --git a/src/test/regress/expected/opr_sanity.out b/src/test/regress/expected/opr_sanity.out index 8aba9f87b2..0be263e6d8 100644 --- a/src/test/regress/expected/opr_sanity.out +++ b/src/test/regress/expected/opr_sanity.out @@ -773,7 +773,7 @@ WHERE p1.amopclaid = 0 OR p1.amopstrategy <= 0 OR p1.amopopr = 0; SELECT p1.amopclaid, p1.amopopr, p2.oid, p2.amname FROM pg_amop AS p1, pg_am AS p2, pg_opclass AS p3 WHERE p1.amopclaid = p3.oid AND p3.opcamid = p2.oid AND - p1.amopstrategy > p2.amstrategies; + p1.amopstrategy > p2.amstrategies AND p2.amstrategies <> 0; amopclaid | amopopr | oid | amname -----------+---------+-----+-------- (0 rows) @@ -781,12 +781,11 @@ WHERE p1.amopclaid = p3.oid AND p3.opcamid = p2.oid AND -- Detect missing pg_amop entries: should have as many strategy operators -- as AM expects for each opclass for the AM. When nondefault subtypes are -- present, enforce condition separately for each subtype. --- We have to exclude GiST and GIN, unfortunately, since they haven't got --- any fixed requirements about strategy operators. +-- We can't check this for AMs with variable strategy sets. SELECT p1.oid, p1.amname, p2.oid, p2.opcname, p3.amopsubtype FROM pg_am AS p1, pg_opclass AS p2, pg_amop AS p3 WHERE p2.opcamid = p1.oid AND p3.amopclaid = p2.oid AND - p1.amname != 'gist' AND p1.amname != 'gin' AND + p1.amstrategies <> 0 AND p1.amstrategies != (SELECT count(*) FROM pg_amop AS p4 WHERE p4.amopclaid = p2.oid AND p4.amopsubtype = p3.amopsubtype); diff --git a/src/test/regress/sql/opr_sanity.sql b/src/test/regress/sql/opr_sanity.sql index 8428624582..7fc9915275 100644 --- a/src/test/regress/sql/opr_sanity.sql +++ b/src/test/regress/sql/opr_sanity.sql @@ -642,18 +642,17 @@ WHERE p1.amopclaid = 0 OR p1.amopstrategy <= 0 OR p1.amopopr = 0; SELECT p1.amopclaid, p1.amopopr, p2.oid, p2.amname FROM pg_amop AS p1, pg_am AS p2, pg_opclass AS p3 WHERE p1.amopclaid = p3.oid AND p3.opcamid = p2.oid AND - p1.amopstrategy > p2.amstrategies; + p1.amopstrategy > p2.amstrategies AND p2.amstrategies <> 0; -- Detect missing pg_amop entries: should have as many strategy operators -- as AM expects for each opclass for the AM. When nondefault subtypes are -- present, enforce condition separately for each subtype. --- We have to exclude GiST and GIN, unfortunately, since they haven't got --- any fixed requirements about strategy operators. +-- We can't check this for AMs with variable strategy sets. SELECT p1.oid, p1.amname, p2.oid, p2.opcname, p3.amopsubtype FROM pg_am AS p1, pg_opclass AS p2, pg_amop AS p3 WHERE p2.opcamid = p1.oid AND p3.amopclaid = p2.oid AND - p1.amname != 'gist' AND p1.amname != 'gin' AND + p1.amstrategies <> 0 AND p1.amstrategies != (SELECT count(*) FROM pg_amop AS p4 WHERE p4.amopclaid = p2.oid AND p4.amopsubtype = p3.amopsubtype); |
