btree index maximum row size

Started by PG Bug reporting formabout 6 years ago3 messagesdocs
Jump to latest
#1PG Bug reporting form
noreply@postgresql.org

The following documentation comment has been logged on the website:

Page: https://www.postgresql.org/docs/12/limits.html
Description:

Appendix K (PostgreSQL Limits) - doesn't mention the (btree) index row size
limits. I think that it should.

#2Bruce Momjian
bruce@momjian.us
In reply to: PG Bug reporting form (#1)
Re: btree index maximum row size

On Mon, Feb 3, 2020 at 07:09:19PM +0000, PG Doc comments form wrote:

The following documentation comment has been logged on the website:

Page: https://www.postgresql.org/docs/12/limits.html
Description:

Appendix K (PostgreSQL Limits) - doesn't mention the (btree) index row size
limits. I think that it should.

Sorry for the delay in replying. We do get questions about the btree
length limit occasionally, but practically the length limit usually
isn't a problem. Unless you need ordered data, a hash index is a better
choice for long values than btree because the hashes are much shorter.
Expression indexes can also help.

What is your use-case for indexing very long values?

--
Bruce Momjian <bruce@momjian.us> https://momjian.us
EnterpriseDB https://enterprisedb.com

+ As you are, so once was I.  As I am, so you will be. +
+                      Ancient Roman grave inscription +
In reply to: Bruce Momjian (#2)
Re: btree index maximum row size

On Thu, Mar 12, 2020 at 5:17 PM Bruce Momjian <bruce@momjian.us> wrote:

Sorry for the delay in replying. We do get questions about the btree
length limit occasionally, but practically the length limit usually
isn't a problem.

Technically the limitation is documented elsewhere, since it is a
limitation of the B-Tree access method specifically. However, I think
that there is a good practical argument to be made for including it
here as well.

--
Peter Geoghegan