Bruce,

It might help, maybe not, but Pragmatic Programmers has a book called SQL 
AntiPatterns with Chapter 3 dedicated to tree structures in databases

http://pragprog.com/book/bksqla/sql-antipatterns

They show several alternatives to the usual starting point of adjacency 
lists to describe trees in databases.

I don't understand your problem domain of MLM and I guess am not sure why 
there would be only left and right child nodes at a particular level, I 
would think a person could sponsor more than 2 people.

The book discusses the SQL99 WITH keyword for recursive queries which 
PostgreSQL supports since 8.,4 as well as alternative ways to express a 
hierarchy in a table.

Hope it is some use.

Ron

Reply via email to