I have a data structure where I'm looking up a group of objects that are linked linearly. Imagine that I have a table where towns are linked to houses, houses linked to owners and owners linked to dogs.
towns are not linked directly to dogs so if I want dogs in a town I end up with a wild self join all from one table:
select thing from table1 t1, table1 t2, table1 t3 where t1.location = t2.thing and t2.thing = t3.location etc...
My question: will using a pivot vs simple joins make this faster? If so why?
Thanks!
1 reply to this topic
1 user(s) are reading this topic
0 members, 1 guests, 0 anonymous users


Sign In
Create Account


Back to top









