pg.ddx.io  pgsql-general@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Tom Lane <tgl@sss.pgh.pa.us>
To: Anthony Mallgren <abmallgren@gmail.com>
Cc: pgsql-general@postgresql.org
Subject: Re: Skipping Inserts
Date: Tue, 22 Sep 2026 12:16:45 -0400
Message-ID: <1186122.1790093805@sss.pgh.pa.us> (raw)
In-Reply-To: <CAGhVYuy8+qXo0D4N+Kxt6pf=j3MTeMA9g0uAO2joQjayLGZLug@mail.gmail.com>
References: <CAGhVYuy8+qXo0D4N+Kxt6pf=j3MTeMA9g0uAO2joQjayLGZLug@mail.gmail.com>

Anthony Mallgren <abmallgren@gmail.com> writes:
> I'm getting a lot of messages like this:
> [warn] skipped a 3-word n-gram: table tid from new index tuple (2524,87)
> cannot find insert offset between offsets 2 and 16 of block 36 in index
> "congress_103_3_word_word1_idx"

I don't know about the first part of that, maybe it's from your
application?  But the "table tid ..." part matches this:

            /*
             * postingoff should never be set more than once per leaf page
             * binary search.  That would mean that there are duplicate table
             * TIDs in the index, which is never okay.  Check for that here.
             */
            if (insertstate->postingoff != 0)
                ereport(ERROR,
                        (errcode(ERRCODE_INDEX_CORRUPTED),
                         errmsg_internal("table tid from new index tuple (%u,%u) cannot find insert offset between offsets %u and %u of block %u in index \"%s\"",
                                         ItemPointerGetBlockNumber(key->scantid),
                                         ItemPointerGetOffsetNumber(key->scantid),
                                         low, stricthigh,
                                         BufferGetBlockNumber(insertstate->buf),
                                         RelationGetRelationName(rel))));

So this code thinks your index is corrupt.  REINDEX should help.

			regards, tom lane





view thread (4+ messages)  latest in thread

Message-ID: <1186122.1790093805@sss.pgh.pa.us>
Permalink:  ../1186122.1790093805@sss.pgh.pa.us/
Also on:    postgresql.org/message-id/1186122.1790093805@sss.pgh.pa.us

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-general@postgresql.org
  Cc: tgl@sss.pgh.pa.us, abmallgren@gmail.com
  Subject: Re: Skipping Inserts
  In-Reply-To: <1186122.1790093805@sss.pgh.pa.us>
  References: <CAGhVYuy8+qXo0D4N+Kxt6pf=j3MTeMA9g0uAO2joQjayLGZLug@mail.gmail.com> <1186122.1790093805@sss.pgh.pa.us>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox