Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> comp.databases.theory -> Re: Nested Sets vs. Nested Intervals

Re: Nested Sets vs. Nested Intervals

From: asdf <xyz91234_at_yahoo.com>
Date: 16 Nov 2005 12:33:56 -0800
Message-ID: <1132173236.896624.281520@z14g2000cwz.googlegroups.com>


The array of folders for:

http://dir.example.com/Games/Board_Games/Abstract/Chess/Software/Web_Chess_Viewers/

is:

folders[0] = 'Games'
folders[1] = 'Board Games'
folders[2] = 'Abstract'
folders[3] = 'Chess'

...

so the id can be queried very efficiently by first getting the ID for the row name = 'Games' AND parent = 0, since the main category's id is
'0'. It then gets the id for the category called 'Games' and continue
on with name='Board Games' AND parent equals the id for the row named
'Board Games', then continues on until it ends on the last element of
the array. So this is very efficient. It has to do multiple SELECTs. Are multiple SELECTs efficient?

Getting the path does not require multiple JOINs, just multiple SELECTs, so the speed is equal to getting the id from the path shown above.

So what are the advantages for Nested Intervals? What are the differences in terms of speed between Nested Intervals and LDAP?
Is this method more efficient than the speed of LDAP? Received on Wed Nov 16 2005 - 14:33:56 CST

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US