Search code examples
sqlsql-server-2008tempdbsql-execution-plan

Query Stuck in Suspended mode with IO_Completition as Wait Type


I am running a query in SQL Server 2008r2, it is stuck with

Task State: Suspended (Sometimes changes to Running but mostly Suspended)

Wait Type: IO_Completion.

There is another query running on the tempdb at the same time.

Is there any way to solve this issue?

Thanks


Solution

  • The problem was due to a join returning too many rows as intermediary results.

    I changed the join order and forced the query to run in that order, it solved the problem.