(Republishing, or using this info in a commercial product/website, is prohibited without permission. All other uses are permitted. If in doubt, please ask.)

(Back to main page…)


This wait type is when a thread is involved in a batch-mode sort (only around columnstore indexes prior to SQL Server 2019).

(Books Online description: N/A)

Questions/comments on this wait type? Click here to send Paul an email, especially if you have any information to add to this topic.

Added in SQL Server version:


Removed in SQL Server version:


Extended Events wait_type value:

Maps to the BATCH_MODE_SORT map_value in sys.dm_xe_map_values.

The map_key value in sys.dm_xe_map_values is 1062 in 2016 RTM. After 2016 RTM, you must check the DMV to get the latest value as some map_key values have changed in later builds.

Other information:

In some situations on SQL Server 2016, a batch mode sort may be very inefficient and so trace flag 9358 was added that allows them to be disabled – see this KB article for details. Anecdotal evidence is that when this inefficiency happens, it can appear like a non-yielding scheduler where the query never completes. Further anecdotal evidence is that even post 2016 CU1, this trace flag is needed in some situations.

Known occurrences in SQL Server (list number matches call stack list):

  1. TBD

Abbreviated call stacks (list number matches known occurrences list):

  1. TBD