PostgreSQL 13: error number of items mismatch in GIN entry tuple, 2 in tuple header, 19 decoded
Asked Answered
J

1

6

I stuck with a problem with PostgreSQL at GCP that at some moment PostgreSQL starts to raise an error

number of items mismatch in GIN entry tuple, 2 in tuple header, 19 decoded 

It happens after insert in the table with GIN index on JSONB field
After the first occurrence of the error, it will occur regularly, but not on every insert operation

I tried to reinsert to test DB the same rows, several rows before and after the error appeared, everything was inserted successfully

Also, I see in the Postgres logs before the error starts to appear: automatic analyze of table <table-name>, maybe it can be helpful

Joli answered 26/3, 2021 at 15:0 Comment(0)
G
2

That is some kind of data corruption. If you want that investigated, you'll have to ask your hosting provider.

To get rid of the message, rebuild the index using REINDEX.

Gona answered 26/3, 2021 at 16:22 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.