From: | Craig Ringer <craig(at)2ndquadrant(dot)com> |
---|---|
To: | soroosh sardari <soroosh(dot)sardari(at)aut(dot)ac(dot)ir> |
Cc: | David Johnston <polobo(at)yahoo(dot)com>, PostgreSQL Hackers <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: A general Q about index |
Date: | 2013-07-17 05:26:10 |
Message-ID: | 51E62AF2.8050303@2ndquadrant.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On 07/16/2013 11:09 PM, soroosh sardari wrote:
>
> Actually I mean the index in the source code, I want to know how index
> is used in the backend for
> execution of some query.
> sorry my question is a bit ambiguous,
> I start to read "src/backend/access/index/genam.c", and I think maybe
> this file is not good way to start.
> let me write a bunch of question to illustrate my point,
> -How create an index for a table with specified field
> -How index is stored in a page
> -what module is responsible to fetch and swap out index pages
> -Is there a kind of abstract class for all variant of index?
Start with the documentation:
http://www.postgresql.org/docs/current/static/internals.html
particularly:
http://www.postgresql.org/docs/current/static/indexam.html
http://www.postgresql.org/docs/current/static/gist.html
http://www.postgresql.org/docs/current/static/catalog-pg-index.html
http://www.postgresql.org/docs/current/static/catalog-pg-am.html
That should give you the ground work to understand the source code a bit
better. Then feel free to return with specific questions you don't feel
are explained by the documentation or code comments and aren't obvious
from the code.
--
Craig Ringer http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Training & Services
From | Date | Subject | |
---|---|---|---|
Next Message | Fabien COELHO | 2013-07-17 06:17:54 | Re: [PATCH] pgbench --throttle (submission 7 - with lag measurement) |
Previous Message | Ants Aasma | 2013-07-17 03:36:26 | Re: Improvement of checkpoint IO scheduler for stable transaction responses |