February 20, 2013 at 11:49 am
I have a situation with items that are related, but not really in a heirarchy ... more like parent to parent. As shown below, all the ODD numbers are related to each other equally so that '1' is related to '11' via the other entries. ie, 5 is related to 1, and 11 is related to 5, therefore 11 is related to 1.
And all the EVEN numbers are related to each other equally, so that '12' is related to '2' because 12 is related to 10, 10 is related to 8, and 8 is related to 2.
I need to consolidate related rows into 1 summary row (selecting oldest & newest dates), and looking for examples on the InterWebz, but not sure what keywords I should be looking for to describe this kind of relationship.
Item_AItem_B
51
64
73
82
97
106
108
115
119
1210
May 16, 2013 at 3:37 pm
With the ODD numbers, how is 7,5,3 related. Did you miss 7 is related to five?
thanks
----------------------------------------------------
May 17, 2013 at 3:20 am
It's a tree or hierarchy, whatever you prefer.
I guess, you will need to use some sort of recursive CTE. Hard to say anything more based on provided limited details.
Viewing 3 posts - 1 through 2 (of 2 total)
You must be logged in to reply to this topic. Login to reply