Since you can't write all 4 concurrently then try to union directly to your queries as below,
Select a, b, cFrom([Query From cte1] join [Query From cte2))UnionSelect x, y, zFrom([Query From cte3] join [Query From cte4))
No comments:
Post a Comment