clustering index



IBM's flagship relational database management system

clustering index

Postby makkena » Tue Apr 19, 2011 11:44 am

can some one pls provide me the best mnual for understanding wt is clustering index. i am not able to get the good one in google.
makkena
 
Posts: 9
Joined: Wed Mar 16, 2011 2:02 pm
Has thanked: 0 time
Been thanked: 0 time

Re: clustering index

Postby alexm » Tue Apr 19, 2011 4:59 pm

Question here is what's a "good one"...
Have a look at this excerpt of an IBM manual, or get an idea from this blog.

The important thing is:
[...] causes DB2 to insert the records as nearly as possible in the order of their index values [...]
User avatar
alexm
 
Posts: 35
Joined: Wed Oct 13, 2010 6:40 pm
Has thanked: 0 time
Been thanked: 0 time

Re: clustering index

Postby Suny » Thu Apr 21, 2011 4:16 pm

I cannot point to a good manual (difficult to define whats good) but I will try to get you a start here. The logic is same as KSDS VSAM index logic.
Ok, So now you have a Db2 table without any index. You define an index now and do a Build index (possibly a reorg to get a correct sequence). The index values sequence will have the same sequence to DB2 rows. Now if you try to insert a row whose index falls somewhere in between , Db2 will try to insert the row in the corresponding location by utilizing the freespace in a page.
Suny
 
Posts: 8
Joined: Thu Apr 21, 2011 3:57 pm
Has thanked: 0 time
Been thanked: 0 time


Return to DB2

 


  • Related topics
    Replies
    Views
    Last post