Skip site navigation (1) Skip section navigation (2)

Re: RTREE Index on primary key generated by a sequence

From: Jean-Paul ARGUDO <jean-paul(dot)argudo(at)IDEALX(dot)com>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: pgsql-hackers(at)postgresql(dot)org
Subject: Re: RTREE Index on primary key generated by a sequence
Date: 2002-01-25 15:55:58
Message-ID: 20020125155558.GA31304@pastis (view raw, whole thread or download thread mbox)
Lists: pgsql-hackers

Since my english is not so fluent, I found on the net a little
explication about Reverse Key Indexes (not RTREE, sorry :).

As an explication, you could read there the point 9 :

Wich I copy here : «

9.Use Reverse Key Indexes. An index block
typically references more rows than are
contained in each data block for the
corresponding table. When an index is based on
a column that increases in a sequential
fashion, and two or more instances are
inserting data into the underlying
table, there is a strong likelihood that both
instances will be contending for the
same index block. This is because sequential
index entries are likely to be in the
same block. Reverse key indexes reverse the
bytes in each index entry, causing
sequential entries to be dispersed across the
index tree. Hence, there is less chance
of contention for the same index block. One
trade-off involved with using this
technique is that by its nature, reverse key indexes
cannot be used as the basis for an index
range scan. 



Jean-Paul ARGUDO                     		IDEALX S.A.S
Consultant bases de données			15-17, av. de Ségur 				F-75007 PARIS

In response to


pgsql-hackers by date

Next:From: Jean-Paul ARGUDODate: 2002-01-25 15:57:00
Subject: Fwd: Re: RTREE Index on primary key generated by a sequence
Previous:From: Tom LaneDate: 2002-01-25 15:40:56
Subject: Re: typo in contrib/oid2name

Privacy Policy | About PostgreSQL
Copyright © 1996-2017 The PostgreSQL Global Development Group