Skip to main content

Restrict memory usage on Microsoft SQL Server / SQL Express

Article # 3016563 - Page views: 1258


In order to verfiy the current memory restriction on your SQL Server / SQL Express you can run the query "currentmemory.sql" attached.

To define a new memory restriction you can run the query "setmaxmemory.sql".

The query is currently set to 256MB, you can edit the value depending on your needs:

EXEC sp_configure 'max server memory (MB)', 256;

-- here the max memory used by the sql instance is 256MB

Further details can be found in Microsoft KB 178067