Sp_configure 'show advanced options', 1;
Go
Reconfigure;
Go
Sp_configure 'min Server Memory ', 2048;
Go
Reconfigure;
Go
Sp_configure 'max Server Memory ', 2560;
Go
Reconfigure;
Go
Sp_configure 'show advanced options', 0;
Go
Reconfigure;
Go
After this script is run, you do not need to restart the database. If you set it through the interface, you need to restart.
In fact, transact-SQL is the core of SQL Server. All applications that communicate with SQL Server instancesProgramYou can send a Transact-SQL statement to the server for communication, regardless of the user interface of the application. In many cases, it is faster and more effective to directly use scripts than to set them through a friendly interface, or even through scripts. For example, to back up a database, use a script faster. To create a larger table index, use the interface to prompt timeout, while the script does not need to worry.