min memory per query (KB)
Smallest memory grant a query that sorts or hashes receives.
- Padrão
1024- Range
- 512 to 2147483647 KB
- Restart needed
- Não
- Default checked on
- SQL Server 2025
O que faz
Each query with a sort or hash gets at least this much workspace memory, even if the optimizer estimated less.
Valor padrão
1024. 1024 KB (SQL Server 2025).
Check the current value
SELECT name, value, value_in_use, minimum, maximum, is_dynamic, is_advanced FROM sys.configurations WHERE name = 'min memory per query (KB)'; -- EXEC sp_configure 'min memory per query (KB)'; also works, but only while show advanced options is 1; -- otherwise it fails with Msg 15123 because this is an advanced option.
Change it
EXEC sp_configure 'show advanced options', 1; RECONFIGURE; EXEC sp_configure 'min memory per query (KB)', 2048; RECONFIGURE;
No restart: it takes effect when RECONFIGURE runs (sys.configurations.is_dynamic = 1). It is an advanced option, so show advanced options must be on to change it.
When to change it
Rarely. Memory grant feedback and better statistics are the usual fixes for spills.
What can go wrong
Higher values make every grant larger, so fewer queries run before others wait on RESOURCE_SEMAPHORE.
Questions about min memory per query (KB)
What is the default value of min memory per query (KB) in SQL Server?
1024. 1024 KB (SQL Server 2025).
Does changing min memory per query (KB) require a restart?
No. No restart: it takes effect when RECONFIGURE runs (sys.configurations.is_dynamic = 1). It is an advanced option, so show advanced options must be on to change it.
When should I change min memory per query (KB)?
Rarely. Memory grant feedback and better statistics are the usual fixes for spills.
Back to all SQL Server settings, or check the SQL Server manual for every option.
Check min memory per query (KB) on your own server
SQLly runs the query above against SQL Server and the other engines in this reference, from one desktop app on macOS, Windows and Linux.