Search code examples
sql-servert-sqlquery-performance

Why is parallelism bad in execution plans


People seem to hint that when the yellow arrows appear in the execution plan it is a bad sign. Why is it a problem that a query runs in parallel?


Solution

  • It's not a bad sign. Depending on certain settings the engine may decide to use parallel operators in order to optimize the execution of certain T-SQL statements. In most of the cases it will make the better choice (either to use or not to use).

    If you are worried about the engine not taking the better decision you can change the Max Degree of Parallelism and Cost Threshold For Parallelism. Anyway, there are hints to force the parallel execution, too - Forced Parameterization.

    I personally, have tried forcing parallel operations and denying them in order to debug/improve performance but in the end I always leave it to the engine to make these decisions instead of me.