Q:

how can I relate two nodes in different rows in a nested model tree?

how can I  relate Fruit and Meat when Fruit or Meat are call and display both of them? I have use a couple of calculations in between their nodes numbers 2,11,12,17 ran out of calculus. can you think of a equation to solve this problem?

A:

Each entry needs to have a "parent" association so you know how to build the tree. You can relate those nodes as they would have the same parent. Or if you needed to relate items at a particular level, such "Red" and "Beef", that would require something like a recursive CTE in SQL Server 2005 or newer.

