title: Tree data structure in php
body: <p>in my application user starts a new tree or get added under a child-user and keep on adding users in branches in such a way-<br>
  <code>&gt;</code>there are 10 level of tree type structure.<br>
  <code>&gt;</code>root node contain <code>1</code> user and each node(user) can have <strong>max</strong> <code>5</code> child-user in this way tree  will be like <code>level 0 = 1 user</code> ,<br>
  <code>level 1 = 5 user</code>,<br>
   <code>level 2 = 25 user</code> ,<br>
  <code>level 3 = 125 user</code> and so on.</p>
  
  <p>I created one MySQL table having columns like-</p>
  
  <p><code>User_id</code> , <code>level</code>, <code>super_id</code>, <code>child1_id</code>, <code>child2_id</code>, <code>child3_id</code>, <code>child4_id</code>, <code>child5_id</code></p>
  
  <p><strong>my question is How can I get all child-user(<code>child to child also</code>) of a particular user at any level</strong> do I need to add some more columns in my table??</p>