Re: pg_upgrading to 10.1 corrupts (varchar,varchar) UNIQUE indices

From: rihad <rihad(at)mail(dot)ru>
To: Peter Geoghegan <pg(at)bowt(dot)ie>
Cc: pgsql-general General <pgsql-general(at)postgresql(dot)org>
Subject: Re: pg_upgrading to 10.1 corrupts (varchar,varchar) UNIQUE indices
Date: 2017-12-22 15:07:48
Message-ID: 010482bc-087d-27d3-f18e-8a8b09c3dd89@mail.ru
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On 12/22/2017 07:01 PM, rihad wrote:
> [snip]
> foo=# select bt_index_check('index_users_on_email_and_type');
> ERROR:  item order invariant violated for index
> "index_users_on_email_and_type"
> DETAIL:  Lower index tid=(3,25) (points to index tid=(26,1)) higher
> index tid=(3,26) (points to index tid=(27,1)) page lsn=0/0.
>

Interestingly, another (varchar,varchar) index on a completely different
table doesn't have the problem because it probably doesn't contain any
non-ascii symbols.

 gateway_reference | character varying(255)      | |          |
 gateway_name      | character varying           | |          |

foo=# select
bt_index_check('index_transactions_on_gateway_name_and_gateway_reference');
 bt_index_check
----------------

(1 row)

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Tom Lane 2017-12-22 15:08:56 Re: Intersection or zero-column queries
Previous Message rihad 2017-12-22 15:01:58 Re: pg_upgrading to 10.1 corrupts (varchar,varchar) UNIQUE indices