NYCPHP Meetup

NYPHP.org

[nycphp-talk] Building trees

Jim Hendricks(Biz Computing) jim at bizcomputinginc.com
Wed Oct 16 16:02:49 EDT 2002



>>Figuring out the level at the time a Project is saved is simple since I 
>>have a parent ID, I can walk the tree backwards until I get a 0 ParentID 
>>( 0 is not a legal ProjectID in my design ).  The number of queries I 
>>had to do plus one would be the level of this new item.
>>    
>>
>
>You don't even have to do that. You can just take the level of the
>parent node + 1.
>  
>

Dooh...

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.nyphp.org/pipermail/talk/attachments/20021016/8b8cc767/attachment.html>


More information about the talk mailing list