During some development, I ran into an error message regarding a Subquery (or set of Subqueries).
In effect, I was adding Subqueries to Subselect items from a query such that:
... where [ThisID] in (Select [ID] from [Bar] where ([foo] = A) or ([foo] = B) or ([foo] = C) .... and they tell two friends and they tell two friends...
The runtime error implied that the subquery was "too deep." This was confusing because the number of Subqueries in my application had not changed. However, the number of Clauses added to the Subquery had increased (dramatically).
I throttled the number of clauses that are added to any subquery and the error went away.
However, this raises a question. What is the "length," if that's what one can call it, of a set of subquery clauses? I think this is the cause of my error. I think I was adding too many clauses to a particular subquery and the length was too much.
Does anyone have any experience or ideas?
I corrected the problem (probably caused by a bad pattern on my part) but I'm still curious.