Re: RTREE Index on primary key generated by a sequence - Mailing list pgsql-hackers

From Jean-Paul ARGUDO
Subject Re: RTREE Index on primary key generated by a sequence
Date
Msg-id 20020125155558.GA31304@pastis
Whole thread Raw
In response to Re: RTREE Index on primary key generated by a sequence  (Tom Lane <tgl@sss.pgh.pa.us>)
Responses Re: RTREE Index on primary key generated by a sequence  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-hackers
Tom,

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 :
http://oracle.oreilly.com/news/oraclepp_0900.html

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. 

»


Thanks.

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


pgsql-hackers by date:

Previous
From: Daniel Kalchev
Date:
Subject: Re: RTREE Index on primary key generated by a sequence
Next
From: Hannu Krosing
Date:
Subject: Re: new module contrib/tree for 7.2 ?