Commit de5a08c5 authored by Tom Lane's avatar Tom Lane

Tweak duplicate-index-column regression test to avoid locale sensitivity.

The originally-chosen test case gives different results in es_EC locale
because of unusual rule for sorting strings beginning with "LL".  Adjust
the comparison value to avoid that, while hopefully not introducing new
locale dependencies elsewhere.  Per report from Jaime Casanova.
parent 50363c8f
......@@ -2468,18 +2468,18 @@ CREATE INDEX dupindexcols_i ON dupindexcols (f1, id, f1 text_pattern_ops);
VACUUM ANALYZE dupindexcols;
EXPLAIN (COSTS OFF)
SELECT count(*) FROM dupindexcols
WHERE f1 > 'LX' and id < 1000 and f1 ~<~ 'YX';
WHERE f1 > 'MA' and id < 1000 and f1 ~<~ 'YX';
QUERY PLAN
---------------------------------------------------------------------------------
Aggregate
-> Index Only Scan using dupindexcols_i on dupindexcols
Index Cond: ((f1 > 'LX'::text) AND (id < 1000) AND (f1 ~<~ 'YX'::text))
Index Cond: ((f1 > 'MA'::text) AND (id < 1000) AND (f1 ~<~ 'YX'::text))
(3 rows)
SELECT count(*) FROM dupindexcols
WHERE f1 > 'LX' and id < 1000 and f1 ~<~ 'YX';
WHERE f1 > 'MA' and id < 1000 and f1 ~<~ 'YX';
count
-------
500
497
(1 row)
......@@ -816,6 +816,6 @@ VACUUM ANALYZE dupindexcols;
EXPLAIN (COSTS OFF)
SELECT count(*) FROM dupindexcols
WHERE f1 > 'LX' and id < 1000 and f1 ~<~ 'YX';
WHERE f1 > 'MA' and id < 1000 and f1 ~<~ 'YX';
SELECT count(*) FROM dupindexcols
WHERE f1 > 'LX' and id < 1000 and f1 ~<~ 'YX';
WHERE f1 > 'MA' and id < 1000 and f1 ~<~ 'YX';
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment