pg.ddx.io  pgsql-general@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Tom Lane <tgl@sss.pgh.pa.us>
To: Marc Millas <marc.millas@mokadb.com>
Cc: pgsql-general@lists.postgresql.org <pgsql-general@lists.postgresql.org>
Subject: Re: index unique
Date: Tue, 08 Jun 2021 16:05:14 -0400
Message-ID: <1175436.1623182714@sss.pgh.pa.us> (raw)
In-Reply-To: <CADX_1aagcNrVGyr6up_pRGdRJBJtQxcMAT=9PKkuRKnBG0BpxA@mail.gmail.com>
References: <CADX_1aYbmMHK4wqHd=p_fGsNMOgEB7oe0BY_9ZTWv3e-TQx+oA@mail.gmail.com>
	<20210607065501.GA17125@hjp.at>
	<CAKFQuwbBZQTLtYRxaJUfGFGj60vmcEYCsxiw3tAj1U12kR3TiA@mail.gmail.com>
	<20210607220848.GB17125@hjp.at>
	<CADX_1aZEC0+AhHyWW=9C251F4DTxoWnENktqVP17h_=JXC5-5A@mail.gmail.com>
	<20210608184212.GA9580@hjp.at>
	<CADX_1aagcNrVGyr6up_pRGdRJBJtQxcMAT=9PKkuRKnBG0BpxA@mail.gmail.com>

Marc Millas <marc.millas@mokadb.com> writes:
> I know, its clearly stated in postgres doc about btree," The only
> limitation is that an index entry cannot exceed approximately one-third of
> a page (after TOAST compression, if applicable)."

Yup.

> is there any plan to adress this ?

No.  The cost/benefit ratio seems completely untenable.

The usual recommendation is that you shorten long values by hashing
them, eg create a unique index on md5(my_long_column).

			regards, tom lane





view thread (16+ messages)  latest in thread

Message-ID: <1175436.1623182714@sss.pgh.pa.us>
Permalink:  ../1175436.1623182714@sss.pgh.pa.us/
Also on:    postgresql.org/message-id/1175436.1623182714@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, marc.millas@mokadb.com
  Subject: Re: index unique
  In-Reply-To: <1175436.1623182714@sss.pgh.pa.us>
  References: <CADX_1aYbmMHK4wqHd=p_fGsNMOgEB7oe0BY_9ZTWv3e-TQx+oA@mail.gmail.com> <20210607065501.GA17125@hjp.at> <CAKFQuwbBZQTLtYRxaJUfGFGj60vmcEYCsxiw3tAj1U12kR3TiA@mail.gmail.com> <20210607220848.GB17125@hjp.at> <CADX_1aZEC0+AhHyWW=9C251F4DTxoWnENktqVP17h_=JXC5-5A@mail.gmail.com> <20210608184212.GA9580@hjp.at> <CADX_1aagcNrVGyr6up_pRGdRJBJtQxcMAT=9PKkuRKnBG0BpxA@mail.gmail.com> <1175436.1623182714@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