If sort large volume of data, then sql server prefers to allocate a large memory to sort them all in memory, say one sort need 30G. And the sql server has 300G, but only 5G is left as all others are used, then sql server will wait to allocate
30G for some time, and then if it waits too long, it will allocate the min required memory to do the sort which will result in IO in tempdb. My question is how long sql server will wait before it choose to allocate less optimized memory.
↧