Problem with UNION ALL

  • If I use UNION ALL and combine the results of two queries, my application works fine.

    But I observe that the queries are executed serially.

    Can I get both queries executed in parallel to improve performance?

  • Nope. It's going to execute them one after the other and combine the data.

    "The credit belongs to the man who is actually in the arena, whose face is marred by dust and sweat and blood"
    - Theodore Roosevelt

    Author of:
    SQL Server Execution Plans
    SQL Server Query Performance Tuning

  • i have the same problem in a security database i admin. we dump event logs to it and every server monitored has at least one table. some reports have a dozen or more union all's to bring up the data. looking to start merging a lot of the data into fewer tables and rework the queries

Viewing 3 posts - 1 through 2 (of 2 total)

You must be logged in to reply to this topic. Login to reply