Re: AW: AW: [PEAR-DEV] DB_NestedSet_MDB useless

From: Date: Tue, 01 Jul 2003 14:55:07 +0000
Subject: Re: AW: AW: [PEAR-DEV] DB_NestedSet_MDB useless
References: 1  Groups: php.pear.dev 
Request: Send a blank email to pear-dev+get-17902@lists.php.net to get a copy of this message
Daniel Khan wrote:
Hello Jeroen,
A bit offtopic, but I'd like to know the difference between nested set and PEAR::Tree. Can someone elaborate on this please?
       
Thanks for the info. I use PEAR::Tree at the moment, and it works fine so there really is no need for me to switch to a different backend, but I lighter package that only deals with DB's would be better for my specific case. Also PEAR::Tree is still beta so I guess it's always better to find a stable package. However the link you sent me says PEAR::DB_NestedSet can only be used with MySql. Is that true? Surely if is uses PEAR::DB it must be able to handle PostgreSQL as well.
Postgres people are very proud to be able to use stored procedures for that as I heared :) The only problem is one kind of query which cotians if's. I'm not sure if this will work with postgres but if someone could test and report the result to me I would be happy.
I think I use a differnt approach for my tree so maybe I'm not using a nested set tree. I have the following table :
[..]
Can I make that work with nestedset? TIA
Hm - it's no NestedSet. What do you exactly want to do? What is the question? basically what I use it for is to create a filesystem type system in a database. Users can create folders (I call them sections) with an unlimited number an subfolders. With PEAR::Tree I can easily read a tree starting from a specific folder and display it in a javascript menu (not HTML_TreeMenu, but similar).
So if I understand correctly, DB_NestedSet is for nested sets (duh!) and perhaps PEAR::Tree is for "my" way of storing trees, using a plain "id -> parent_id" structure. Did I explain myself properly? jeroen

« previous php.pear.dev (#17902) next »