for example i have a bug "TREE" in my DB
that's its final result look''s like this :
http://www.mattkruse.com/javascript/mktree/
now i my DB i hold rows like this
node_id | parent_id | name(text)
now when i pull the data from the table like :
"select * from tables tree"
i recive a record set with all the rows in the DB!
now i want to send to the client the correct structre of the tree including it's subtitles,and the subtitles of the subtitles and so on
.....
what is the best way to build a structured array or what ever so the final tree will look like the one in the example?
thnaks in advance
peleg