1
0
mirror of https://github.com/postgres/postgres.git synced 2025-10-19 15:49:24 +03:00

Rename amcancrosscompare

After more discussion about commit ce62f2f2a0, rename the index AM
property amcancrosscompare to two separate properties
amconsistentequality and amconsistentordering.  Also improve the
documentation and update some comments that were previously missed.

Reported-by: Tom Lane <tgl@sss.pgh.pa.us>
Discussion: https://www.postgresql.org/message-id/flat/E1tngY6-0000UL-2n%40gemulon.postgresql.org
This commit is contained in:
Peter Eisentraut
2025-03-07 10:51:53 +01:00
parent 6da469bada
commit af4002b381
12 changed files with 41 additions and 26 deletions

View File

@@ -1083,9 +1083,10 @@ query_supports_distinctness(Query *query)
* the values are distinct. (Note: the opids entries could be cross-type
* operators, and thus not exactly the equality operators that the subquery
* would use itself. We use equality_ops_are_compatible() to check
* compatibility. That looks at btree or hash opfamily membership, and so
* should give trustworthy answers for all operators that we might need
* to deal with here.)
* compatibility. That looks at opfamily membership for index AMs that have
* declared that they support consistent equality semantics within an
* opfamily, and so should give trustworthy answers for all operators that we
* might need to deal with here.)
*/
bool
query_is_distinct_for(Query *query, List *colnos, List *opids)