Re: BUG #19000: gist index returns inconsistent result with gist_inet_ops - Mailing list pgsql-bugs

From Richard Guo
Subject Re: BUG #19000: gist index returns inconsistent result with gist_inet_ops
Date
Msg-id CAMbWs49vGc45oQ98bhx4dFpXOsimUX9TTnXOXG=i6+X6sAqBRw@mail.gmail.com
Whole thread Raw
In response to BUG #19000: gist index returns inconsistent result with gist_inet_ops  (PG Bug reporting form <noreply@postgresql.org>)
Responses Re: BUG #19000: gist index returns inconsistent result with gist_inet_ops
List pgsql-bugs
On Mon, Jul 28, 2025 at 5:16 AM PG Bug reporting form
<noreply@postgresql.org> wrote:
> CREATE EXTENSION btree_gist;
>
> CREATE TABLE t AS SELECT '192.168.1.0/25'::inet AS i;
>
> SELECT * FROM t WHERE i << '192.168.1.0/24'::cidr;
>        i
> ----------------
>  192.168.1.0/25
>
> CREATE INDEX ON t USING gist(i);
>
> SELECT * FROM t WHERE i << '192.168.1.0/24'::cidr;
>  i
> ---
> (0 rows)

It seems that with gist_inet_ops the index's opfamily does not support
the '<<' operator correctly.

With inet_ops, the query works correctly.

CC'ing Peter to have a look.

Thanks
Richard



pgsql-bugs by date:

Previous
From: Tom Lane
Date:
Subject: Re: Lower priority of the configure option --with-libraries causes wrong lib resolution
Next
From: shveta malik
Date:
Subject: Re: Unexpected Standby Shutdown on sync_replication_slots change